voidrice/.scripts/lmc
2018-07-29 20:52:57 -04:00

21 lines
640 B
Bash
Executable file

#!/bin/bash
# A general audio interface for LARBS.
newvol="pkill -RTMIN+10 i3blocks"
# Uncomment if i3mpdupdate isn't running:
#newmpd="pkill -RTMIN+11 i3blocks"
case "$1" in
"up") pamixer --allow-boost -i "$2" ; $newvol ;;
"down") pamixer --allow-boost -d "$2" ; $newvol ;;
"mute") pamixer --allow-boost -t ; $newvol ;;
"truemute") pamixer --allow-boost -m ; $newvol ;;
"toggle") mpc toggle ; $newmpd ;;
"pause") mpc pause ; $newmpd ; pauseallmpv ;;
"forward") mpc seek +"$2" ; $newmpd ;;
"back") mpc seek -"$2" ; $newmpd ;;
"next") mpc next ; $newmpd ;;
"prev") mpc prev ; $newmpd ;;
"replay") mpc seek 0% ; $newmpd ;;
esac