1
0
mirror of https://github.com/tiyn/dotfiles.git synced 2025-04-19 16:27:45 +02:00

Compare commits

..

No commits in common. "3917ffaa7c8e07922b121acb131440849681c6b2" and "34c63dd99f852fd898047266fe1a1dedf451f0ab" have entirely different histories.

6 changed files with 21 additions and 48 deletions

View File

@ -16,45 +16,20 @@ if [ "$status" = "Discharging" ] && [ $capacity -le 15 ] ; then
notify-send -u critical "Battery" "Below 15%" notify-send -u critical "Battery" "Below 15%"
fi fi
if [ $capacity -gt 40 ]
then
color="^b#282828^^c#dfdfdf^"
elif [ $capacity -gt 20 ]
then
color="^b#282828^^c#ffff00^"
else
color="^b#282828^^c#ff0000^"
fi
case "$status" in case "$status" in
"Discharging") "Discharging")
if [ $capacity -gt 75 ] icon="^b#282828^^c#dfdfdf^  ^d^";;
then
icon=""
elif [ $capacity -gt 60 ]
then
icon=""
elif [ $capacity -gt 40 ]
then
icon=""
elif [ $capacity -gt 20 ]
then
icon=""
else
icon=""
fi
;;
"Not charging") "Not charging")
icon="";; icon="^b#282828^^c#dfdfdf^  ^d^";;
"Charging") "Charging")
icon="";; icon="^b#282828^^c#dfdfdf^  ^d^";;
"Unknown") "Unknown")
icon="";; icon="^b#282828^^c#dfdfdf^  ^d^";;
"Full") "Full")
icon="⚡";; icon="^b#282828^^c#dfdfdf^ ⚡ ^d^";;
esac esac
capacity=$(echo "$capacity" | sed -e 's/$//') capacity=$(echo "$capacity" | sed -e 's/$//')
capacity=$(printf %3s $capacity | tr ' ' ' ') capacity=$(printf %3s $capacity | tr ' ' ' ')
echo "$color $icon ^d^" echo "$icon $capacity%"

View File

@ -12,12 +12,12 @@ temp=$(printf %3s $(echo ${temp##*+} | sed "s/\..*//") | tr ' ' ' ')
if [ $temp -gt 100 ] if [ $temp -gt 100 ]
then then
icon="^b#282828^^c#ff0000^ " icon="^b#282828^^c#ff0000^  ^d^"
elif [ $temp -gt 80 ] elif [ $temp -gt 80 ]
then then
icon="^b#282828^^c#ffff00^ " icon="^b#282828^^c#ffff00^  ^d^"
else else
icon="^b#282828^^c#dfdfdf^ " icon="^b#282828^^c#dfdfdf^  ^d^"
fi fi
echo "$icon" echo "$icon"

View File

@ -14,12 +14,12 @@ fi
if [ $temp -gt 100 ] if [ $temp -gt 100 ]
then then
icon="^b#282828^^c#ff0000^ " icon="^b#282828^^c#ff0000^  ^d^"
elif [ $temp -gt 80 ] elif [ $temp -gt 80 ]
then then
icon="^b#282828^^c#ffff00^ " icon="^b#282828^^c#ffff00^  ^d^"
else else
icon="^b#282828^^c#dfdfdf^ " icon="^b#282828^^c#dfdfdf^  ^d^"
fi fi
echo "$icon" echo "$icon"

View File

@ -12,12 +12,12 @@ if [ $wifistatus = "up" ]
then then
if [ $wifipercent -gt 75 ] if [ $wifipercent -gt 75 ]
then then
wifiicon="^c#dfdfdf^ ^d^" wifiicon=" ^d^"
elif [ $wifipercent -gt 40 ] elif [ $wifipercent -gt 40 ]
then then
wifiicon="^c#ffff00^ ^d^" wifiicon=" ^d^"
else else
wifiicon="^c#ff0000^ ^d^" wifiicon=" ^d^"
fi fi
fi fi

View File

@ -6,12 +6,12 @@ percent=$(printf %3s $(printf %-4s $total | tr ' ' '0' | cut -c1-4 | sed -e 's/\
if [ $percent -gt 75 ] if [ $percent -gt 75 ]
then then
icon="^b#282828^^c#ff0000^ " icon="^b#282828^^c#ff0000^  ^d^"
elif [ $percent -gt 50 ] elif [ $percent -gt 50 ]
then then
icon="^b#282828^^c#ffff00^ " icon="^b#282828^^c#ffff00^  ^d^"
else else
icon="^b#282828^^c#dfdfdf^ " icon="^b#282828^^c#dfdfdf^  ^d^"
fi fi
echo "$icon" echo "$icon"

View File

@ -2,12 +2,10 @@
vol="$(wpctl get-volume @DEFAULT_AUDIO_SINK@ | awk '{print $2}' | sed -e 's/\.//g' | sed 's/^0*//')" vol="$(wpctl get-volume @DEFAULT_AUDIO_SINK@ | awk '{print $2}' | sed -e 's/\.//g' | sed 's/^0*//')"
if [ "$vol" -gt "100" ]; then if [ "$vol" -eq "0" ]; then
vol_info="^c#ffff00^  " vol_info="^c#dfdfdf^  "
elif [ "$vol" -gt "70" ]; then elif [ "$vol" -gt "70" ]; then
vol_info="^c#dfdfdf^  " vol_info="^c#dfdfdf^  "
elif [ "$vol" -eq "0" ]; then
vol_info="^c#dfdfdf^  "
else else
vol_info="^c#dfdfdf^  " vol_info="^c#dfdfdf^  "
fi fi
@ -21,4 +19,4 @@ else
fi fi
vol=$(printf %3s $vol | tr ' ' ' ') vol=$(printf %3s $vol | tr ' ' ' ')
printf "^b#282828^%s%s^d^" "$mic" "$vol_info" printf "^b#282828^%s%s^d^ %s" "$mic" "$vol_info" "$vol%"