diff options
author | Vikas Kushwaha <dev@vikas.rocks> | 2025-06-13 08:37:31 +0530 |
---|---|---|
committer | Vikas Kushwaha <dev@vikas.rocks> | 2025-06-13 08:37:31 +0530 |
commit | 28ea0e3cbe1c0f980a05d6fb13a428bcab2ea1c5 (patch) | |
tree | b44f5301c4f60b1dae51a91e72b614996ee074ce /.local/bin/statusbar/i3battery | |
parent | 311a468de08231c3dd2327473b79066a25e67462 (diff) |
Diffstat (limited to '.local/bin/statusbar/i3battery')
-rwxr-xr-x | .local/bin/statusbar/i3battery | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/.local/bin/statusbar/i3battery b/.local/bin/statusbar/i3battery index 5b2fb15..17a4dfd 100755 --- a/.local/bin/statusbar/i3battery +++ b/.local/bin/statusbar/i3battery @@ -47,7 +47,7 @@ for battery in /sys/class/power_supply/BAT?*; do *) exit 1 ;; esac # Will make a warn variable if discharging and low - [ "$status" = "Discharging" ] && [ "$capacity" -le 25 ] && warn="❗" + [ "$status" = "Discharging" ] && [ "$capacity" -lt 30 ] && warn="❗" # Prints the info printf "%s%s %d%%" "$warn" "$icon" "$capacity"; unset warn done && printf "\\n" @@ -55,11 +55,11 @@ done && printf "\\n" echo if [ $capacity -ge 80 ]; then echo "$BLOCK_COLOR_LEVEL1" -elif [ $capacity -ge 40 ]; then +elif [ $capacity -ge 60 ]; then echo "$BLOCK_COLOR_LEVEL2" -elif [ $capacity -ge 20 ]; then +elif [ $capacity -ge 40 ]; then echo "$BLOCK_COLOR_LEVEL3" -elif [ $capacity -ge 10 ]; then +elif [ $capacity -ge 20 ]; then echo "$BLOCK_COLOR_LEVEL4" else echo "$BLOCK_COLOR_LEVEL5" |