feat: change the statusbar update calls
This commit is contained in:
parent
10321a0d21
commit
ef4b9b8e93
|
@ -24,3 +24,5 @@ else
|
||||||
|
|
||||||
dunstify -r 100002 -u "$criticity" "Current volume :" "$level%"
|
dunstify -r 100002 -u "$criticity" "Current volume :" "$level%"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
kill -38 $(pidof dwmblocks)
|
||||||
|
|
|
@ -24,14 +24,9 @@ update() { \
|
||||||
# We want the notification to be sent every 5 mins
|
# We want the notification to be sent every 5 mins
|
||||||
# But only if the computer is unplugged
|
# But only if the computer is unplugged
|
||||||
if [ "$(cat /sys/class/power_supply/AC/online)" = 0 ]; then
|
if [ "$(cat /sys/class/power_supply/AC/online)" = 0 ]; then
|
||||||
notify && refbar
|
notify && kill -36 $(pidof dwmblocks)
|
||||||
fi
|
fi
|
||||||
wait
|
wait
|
||||||
}
|
}
|
||||||
|
|
||||||
while :; do
|
update
|
||||||
update
|
|
||||||
# Sleep for 5 minutes before sending another notification
|
|
||||||
sleep 300 &
|
|
||||||
wait
|
|
||||||
done
|
|
||||||
|
|
|
@ -20,3 +20,5 @@ else
|
||||||
|
|
||||||
dunstify -r 10010 -u "normal" -i "$HOME/$path" "MPD" "$out"
|
dunstify -r 10010 -u "normal" -i "$HOME/$path" "MPD" "$out"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
kill -39 $(pidof dwmblocks)
|
||||||
|
|
Reference in New Issue