diff options
Diffstat (limited to 'config/i3blocks/scripts')
-rwxr-xr-x | config/i3blocks/scripts/mpd | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/config/i3blocks/scripts/mpd b/config/i3blocks/scripts/mpd index 63ba924..6594a57 100755 --- a/config/i3blocks/scripts/mpd +++ b/config/i3blocks/scripts/mpd @@ -1,4 +1,20 @@ #!/bin/bash + +case "$BLOCK_BUTTON" in + 1) + mpc toggle >/dev/null + ;; + 2) + mpc stop >/dev/null + ;; + 4) + mpc next >/dev/null + ;; + 5) + mpc prev >/dev/null + ;; +esac + if [ -n "`mpc status | grep -E "(playing|paused)"`" ]; then echo `mpc -f "%artist%, %album%, %title%" status | head -1` echo |