Last active
May 16, 2022 12:18
-
-
Save adpande/ced583c2a7a827f9e217f2fddda8e04b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
sink=alsa_output.pci-0000_0a_00.4.analog-surround-21 | |
# pactl set-default-sink alsa_output.pci-0000_0a_00.4.analog-surround-21 | |
# usage | |
# chmod +x sound.sh | |
# sound.sh <function> | |
default(){ | |
pactl set-default-sink $sink | |
} | |
volup(){ | |
pactl set-sink-volume $sink +5% | |
} | |
voldown(){ | |
pactl set-sink-volume $sink -5% | |
} | |
volmute(){ | |
pactl set-sink-mute $sink toggle | |
} | |
next(){ | |
playerctl --all-players next | |
} | |
prev(){ | |
playerctl --all-players previous | |
} | |
pause(){ | |
playerctl --all-players play-pause | |
} | |
stopit(){ | |
playerctl --all-players stop | |
} | |
spotify(){ | |
spotify | |
} | |
hello(){ | |
echo "Sets the sound card" | |
} | |
"$@" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment