aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohannes Löthberg <johannes@kyriasis.com>2014-04-25 23:56:39 +0200
committerJohannes Löthberg <johannes@kyriasis.com>2014-04-25 23:56:39 +0200
commit0189112e7ed31c8b7a7053ac401dc22af98340f5 (patch)
tree2d400333ba54532427e61d781fbda0541910f859
parent25401108bc8811a93e537b0b99e3dbfa07917b5a (diff)
downloadbin-0189112e7ed31c8b7a7053ac401dc22af98340f5.tar.xz
volumecontrol.bash: import crappy volume controll script
-rwxr-xr-xvolumecontrol.bash19
1 files changed, 19 insertions, 0 deletions
diff --git a/volumecontrol.bash b/volumecontrol.bash
new file mode 100755
index 0000000..285d029
--- /dev/null
+++ b/volumecontrol.bash
@@ -0,0 +1,19 @@
+#!/usr/bin/env bash
+
+if [[ -n "$2" ]]; then
+ step=$2
+else
+ step=5
+fi
+
+case $1 in
+ lower)
+ amixer -D pulse -q set Master $step%-
+ ;;
+ raise)
+ amixer -D pulse -q set Master $step%+
+ ;;
+ mute)
+ amixer -D pulse -q set Master toggle
+ ;;
+esac