aboutsummaryrefslogtreecommitdiffstats
path: root/volumecontrol
blob: 174a30324e85f39b663015042278e795aebc476c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#!/usr/bin/env bash

if [[ -n "$2" ]]; then
	step=$2
else
	step=5
fi

case $1 in
	lower)
		pactl set-sink-mute 1 false
		pactl set-sink-volume 1 -"$step"%
		;;
	raise)
		pactl set-sink-mute 1 false
		pactl set-sink-volume 1 +"$step"%
		;;
	mute)
		pactl set-sink-mute 1 toggle
		;;
esac