From da16306e28acf13751e786ded99e903b09de87fa Mon Sep 17 00:00:00 2001 From: Manuel Palenzuela Date: Sun, 7 Jul 2019 15:21:55 +0200 Subject: Removed acpi depend --- scripts/dwm-status | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/scripts/dwm-status b/scripts/dwm-status index 89d9c7f..559a84d 100755 --- a/scripts/dwm-status +++ b/scripts/dwm-status @@ -153,12 +153,11 @@ status() { \ echo "$delim" # Will show all batteries with approximate icon for remaining power. - ac_adapter=$(acpi -a | cut -d' ' -f3 | cut -d- -f1) - charging="" - if [ "$ac_adapter" == "on" ]; then - echo "" #Charging + ac_adapter=$(cat /sys/class/power_supply/BAT?/status) + if [ "$ac_adapter" == "Charging" ]; then + echo "" else - : #Not Charging + : fi for x in /sys/class/power_supply/BAT?/capacity; -- cgit 1.4.1