1
0
Fork 0

improve sbd scripts

This commit is contained in:
Luca Bilke 2023-02-27 09:34:11 +01:00
parent ee7f68118c
commit 4345787ca2
2 changed files with 7 additions and 4 deletions

View file

@ -1,6 +1,7 @@
#!/bin/sh
# battery status file is sent in as an argument from sb-battery
# while inotifywait -e modify "$1/status"; do
# pkill -RTMIN+3 dwmblocks || break
# done
upower --monitor-detail -i "$1" | while read -r _; do
pkill -RTMIN+3 dwmblocks
timeout 5 cat > /dev/null
done

View file

@ -1,2 +1,4 @@
#!/bin/sh
playerctl status -F | (while read -r _; do pkill -RTMIN+11 dwmblocks; done)
playerctl status -F | while read -r _; do
pkill -RTMIN+11 dwmblocks
done