move more to font-awesome

This commit is contained in:
2023-10-13 12:05:40 +02:00
parent aad4a1c87e
commit d24065a7a5
4 changed files with 9 additions and 25 deletions

View File

@ -1,6 +1,6 @@
#!/bin/sh
# Prints the current volume or 🔇 if muted.
# Prints the current volume or if muted.
case $BLOCK_BUTTON in
1) setsid -w -f "$TERMINAL" -e pulsemixer; pkill -RTMIN+10 "${STATUSBAR:-dwmblocks}" ;;
@ -15,8 +15,8 @@ esac
vol="$(wpctl get-volume @DEFAULT_AUDIO_SINK@)"
# If muted, print 🔇 and exit.
[ "$vol" != "${vol%\[MUTED\]}" ] && echo 🔇 && exit
# If muted, print and exit.
[ "$vol" != "${vol%\[MUTED\]}" ] && echo && exit
vol="${vol#Volume: }"
@ -30,10 +30,10 @@ split() {
vol="$(printf "%.0f" "$(split "$vol" ".")")"
case 1 in
$((vol >= 70)) ) icon="🔊" ;;
$((vol >= 30)) ) icon="🔉" ;;
$((vol >= 1)) ) icon="🔈" ;;
* ) echo 🔇 && exit ;;
$((vol >= 70)) ) icon="" ;;
$((vol >= 30)) ) icon="" ;;
$((vol >= 1)) ) icon="" ;;
* ) echo && exit ;;
esac
echo "$icon$vol%"