diff options
Diffstat (limited to '.scripts')
| -rwxr-xr-x | .scripts/volumechanger | 7 | ||||
| -rwxr-xr-x | .scripts/volumecurr | 10 | 
2 files changed, 17 insertions, 0 deletions
diff --git a/.scripts/volumechanger b/.scripts/volumechanger new file mode 100755 index 0000000..2e97506 --- /dev/null +++ b/.scripts/volumechanger @@ -0,0 +1,7 @@ +#!/bin/sh + +if [ $1 = up ]; then +    wpctl set-volume @DEFAULT_AUDIO_SINK@ 2%+   ##increase by 2% +elif [ $1 = down ];then +    wpctl set-volume @DEFAULT_AUDIO_SINK@ 2%-   ##decrease by 2% +fi diff --git a/.scripts/volumecurr b/.scripts/volumecurr new file mode 100755 index 0000000..7b08cab --- /dev/null +++ b/.scripts/volumecurr @@ -0,0 +1,10 @@ +#!/bin/sh + +volume="$(wpctl get-volume @DEFAULT_SINK@)" +volume=${volume#Volume: *} + +case "$volume"  +    in (*MUTED*) volume=0;;  +esac  + +printf "%0.0f%%\n" "${volume%% *}e+2"  | 
