diff options
| author | ivan-boikov <ik.boikov.public@protonmail.com> | 2024-01-13 20:24:30 +0100 |
|---|---|---|
| committer | ivan-boikov <ik.boikov.public@protonmail.com> | 2024-01-13 20:24:30 +0100 |
| commit | 957dced5d85705e1ae65ca16eb902bd10d67b3e0 (patch) | |
| tree | f190e8e68ab7088b85279959d8ea482b88c72cbb /scripts/.local/bin/sb-volume | |
| parent | c09234bb6e65868ebe83cbf91da83356ee0a2c70 (diff) | |
1
Diffstat (limited to 'scripts/.local/bin/sb-volume')
| -rwxr-xr-x | scripts/.local/bin/sb-volume | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/scripts/.local/bin/sb-volume b/scripts/.local/bin/sb-volume index be07c93..d9387b1 100755 --- a/scripts/.local/bin/sb-volume +++ b/scripts/.local/bin/sb-volume @@ -2,14 +2,14 @@ # Prints the current volume or MUT if muted. -[ $(pamixer --get-mute) = true ] && echo "MUT" && exit - -vol="$(pamixer --get-volume)" - -if [ "$vol" -gt "0" ]; then - icon="" +if [ "$(pamixer --get-mute)" = true ]; then + vol="MUT" else - echo "MUT" && exit + vol="$(pamixer --get-volume)" fi +# for slstatus +printf "%s" "$vol" > /tmp/volume + +# for dwmblocks printf "%3d" $vol |
