1
0
mirror of https://github.com/tiyn/dotfiles.git synced 2025-10-10 03:21:16 +02:00

friendship ended with no bloat, emojis are my new best friend now

This commit is contained in:
TiynGER
2020-03-29 11:27:53 +02:00
parent 9e6cf6dc6f
commit b6d83978a7
3 changed files with 14 additions and 6 deletions

View File

@@ -1,7 +1,15 @@
#!/bin/sh
[ "$(pulsemixer --get-mute)" = "1" ] && printf "M\\n" && exit
[ "$(pulsemixer --get-mute)" = "1" ] && printf "🔇\\n" && exit
vol=$(pulsemixer --get-volume | awk '{print $1}')
printf "%s %%\\n" "$vol"
if [ "$vol" -gt "70" ]; then
icon="🔊"
elif [ "$vol" -lt "30" ]; then
icon="🔈"
else
icon="🔉"
fi
printf "%s %s%%\\n" "$icon" "$vol"