From 62c161c3c133068b00d8fa2e5d5b4a72f193d15b Mon Sep 17 00:00:00 2001 From: tiyn Date: Mon, 11 Mar 2024 00:47:28 +0100 Subject: [PATCH] statusbar: removed volume number for color --- .local/bin/etc/statusbar/volume | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.local/bin/etc/statusbar/volume b/.local/bin/etc/statusbar/volume index d1dcba7..93e04e4 100755 --- a/.local/bin/etc/statusbar/volume +++ b/.local/bin/etc/statusbar/volume @@ -2,10 +2,12 @@ vol="$(wpctl get-volume @DEFAULT_AUDIO_SINK@ | awk '{print $2}' | sed -e 's/\.//g' | sed 's/^0*//')" -if [ "$vol" -eq "0" ]; then - vol_info="^c#dfdfdf^  " +if [ "$vol" -gt "100" ]; then + vol_info="^c#ffff00^  " elif [ "$vol" -gt "70" ]; then vol_info="^c#dfdfdf^  " +elif [ "$vol" -eq "0" ]; then + vol_info="^c#dfdfdf^  " else vol_info="^c#dfdfdf^  " fi @@ -19,4 +21,4 @@ else fi vol=$(printf %3s $vol | tr ' ' ' ') -printf "^b#282828^%s%s^d^ %s" "$mic" "$vol_info" "$vol%" +printf "^b#282828^%s%s^d^" "$mic" "$vol_info"