STATUSBAR uncommented only for i3, cleanup, probably broke everything LOL

This commit is contained in:
Luke Smith
2020-04-10 22:53:45 -04:00
parent 7ada655007
commit 6f36fe3169
13 changed files with 118 additions and 126 deletions

View File

@@ -9,7 +9,7 @@ notify-send "📦 Repository Sync" "Checking for package updates..."
sudo pacman -Syyuw --noconfirm || notify-send "Error downloading updates.
Check your internet connection, if pacman is already running, or run update manually to see errors."
pkill -RTMIN+8 "${STATUSBAR:?}"
pkill -RTMIN+8 "${STATUSBAR:-dwmblocks}"
if pacman -Qu | grep -v "\[ignored\]"
then

View File

@@ -10,8 +10,8 @@ ping -q -c 1 1.1.1.1 > /dev/null || exit
pgrep -x newsboat >/dev/null && /usr/bin/xdotool key --window "$(/usr/bin/xdotool search --name newsboat)" R && exit
echo 🔃 > /tmp/newsupdate
pkill -RTMIN+6 "${STATUSBAR:?}"
pkill -RTMIN+6 "${STATUSBAR:-dwmblocks}"
/usr/bin/newsboat -x reload
rm -f /tmp/newsupdate
pkill -RTMIN+6 "${STATUSBAR:?}"
pkill -RTMIN+6 "${STATUSBAR:-dwmblocks}"
/usr/bin/notify-send "📰 RSS feed update complete."

View File

@@ -11,7 +11,7 @@
updateicon() { \
echo "$1" > /tmp/recordingicon
pkill -RTMIN+9 "${STATUSBAR:?}"
pkill -RTMIN+9 "${STATUSBAR:-dwmblocks}"
}
killrecording() {
@@ -20,7 +20,7 @@ killrecording() {
kill -15 "$recpid"
rm -f /tmp/recordingpid
updateicon ""
pkill -RTMIN+9 "${STATUSBAR:?}"
pkill -RTMIN+9 "${STATUSBAR:-dwmblocks}"
# even after SIGTERM, ffmpeg may still run, so SIGKILL it.
sleep 3
kill -9 "$recpid"
@@ -31,20 +31,20 @@ screencast() { \
ffmpeg -y \
-f x11grab \
-framerate 60 \
-s $(xdpyinfo | grep dimensions | awk '{print $2;}') \
-i $DISPLAY \
-s "$(xdpyinfo | grep dimensions | awk '{print $2;}')" \
-i "$DISPLAY" \
-f alsa -i default \
-r 30 \
-c:v libx264rgb -crf 0 -preset ultrafast -c:a flac \
"$HOME/screencast-$(date '+%y%m%d-%H%M-%S').mkv" &
-c:v h264 -crf 0 -preset ultrafast -c:a aac \
"$HOME/screencast-$(date '+%y%m%d-%H%M-%S').mp4" &
echo $! > /tmp/recordingpid
updateicon "⏺️🎙️"
}
video() { ffmpeg \
-f x11grab \
-s $(xdpyinfo | grep dimensions | awk '{print $2;}') \
-i $DISPLAY \
-s "$(xdpyinfo | grep dimensions | awk '{print $2;}')" \
-i "$DISPLAY" \
-c:v libx264 -qp 0 -r 30 \
"$HOME/video-$(date '+%y%m%d-%H%M-%S').mkv" &
echo $! > /tmp/recordingpid

View File

@@ -2,6 +2,7 @@
# This loop will update the mpd statusbar module whenever a command changes the
# music player's status. mpd must be running on X's start for this to work.
while : ; do
mpc idle >/dev/null && pkill -RTMIN+11 "${STATUSBAR:?}" || break
mpc idle >/dev/null && pkill -RTMIN+11 "${STATUSBAR:-dwmblocks}" || break
done

View File

@@ -3,7 +3,7 @@
printf "Beginning upgrade.\\n"
yay -Syu
pkill -RTMIN+8 "${STATUSBAR:?}"
pkill -RTMIN+8 "${STATUSBAR:-dwmblocks}"
printf "\\nUpgrade complete.\\nPress <Enter> to exit window.\\n\\n"
read -r

View File

@@ -8,4 +8,4 @@ else
ifinstalled transmission-cli || exit
[ "$(printf "No\\nYes" | dmenu -i -p "Start transmission daemon?")" = "Yes" ] && transmission-daemon && notify-send "tranmission-daemon started."
fi
sleep 3 && pkill -RTMIN+7 "${STATUSBAR:?}"
sleep 3 && pkill -RTMIN+7 "${STATUSBAR:-dwmblocks}"

View File

@@ -2,6 +2,6 @@
ifinstalled tremc transmission-cli || exit
! pgrep -x transmission-da >/dev/null && transmission-daemon && notify-send "Starting torrent daemon..." && sleep 3 && pkill -RTMIN+7 "${STATUSBAR:?}"
! pgrep -x transmission-da >/dev/null && transmission-daemon && notify-send "Starting torrent daemon..." && sleep 3 && pkill -RTMIN+7 "${STATUSBAR:-dwmblocks}"
$TERMINAL -e tremc

View File

@@ -4,6 +4,6 @@
# transmission-daemon sometimes fails to take remote requests in its first moments.
pgrep -x transmission-da || (transmission-daemon && notify-send "Starting transmission daemon..." && sleep 3 && pkill -RTMIN+7 "${STATUSBAR:?}")
pgrep -x transmission-da || (transmission-daemon && notify-send "Starting transmission daemon..." && sleep 3 && pkill -RTMIN+7 "${STATUSBAR:-dwmblocks}")
transmission-remote -a "$@" && notify-send "🔽 Torrent added."