more ignores

This commit is contained in:
coolnsx
2024-11-18 11:43:34 +05:30
parent 5c87fbac7d
commit 218a513d60
9 changed files with 85 additions and 118 deletions

View File

@@ -1,9 +1,11 @@
#!/bin/sh
vol_int=$(pamixer --get-volume)
#shellcheck disable=SC2068
wpctl $@
vol=$(wpctl get-volume @DEFAULT_AUDIO_SINK@)
vol_int=$(printf '%s' "$vol" | tr -cd '[:digit:]')
vol_icon="low"
#[ "$vol_int" -gt 0 ] && pamixer -u || pamixer -m
[ "$vol_int" -gt 33 ] && vol_icon="medium"
[ "$vol_int" -gt 66 ] && vol_icon="high"
pamixer --get-mute | sh && vol_icon="muted"
printf '%s' "$vol" | grep -q 'MUTED' && vol_icon="muted"
notify-send -e -i "/usr/share/icons/Papirus/16x16/panel/audio-volume-$vol_icon.svg" "$vol_int %" -h "string:x-canonical-private-synchronous:${0##*/}" -t 1000