move poll to its own function to prep for track_anything.sh
This commit is contained in:
parent
1fccc404ef
commit
70cbf56a3a
|
@ -1,7 +1,11 @@
|
|||
#!/bin/sh
|
||||
|
||||
poll() {
|
||||
pamixer --get-volume | grep -E '^[0-9]+$'
|
||||
}
|
||||
|
||||
pactl subscribe | while read -r ;do
|
||||
case "$REPLY" in
|
||||
*change*) pamixer --get-volume | grep -E '^[0-9]+$';;
|
||||
*change*) poll ;;
|
||||
esac
|
||||
done
|
||||
|
|
Loading…
Reference in New Issue
Block a user