diff --git a/for_smol/bat.sh b/for_smol/bat.sh index bee94ab..2f9a031 100755 --- a/for_smol/bat.sh +++ b/for_smol/bat.sh @@ -7,7 +7,7 @@ then echo "Charging" exit 0 fi -bat=$(acpi -b | cut -b 25-27 | sed 's/%//') +bat=$(acpi -b | sed 's#.*charging, ##;s#%.*##') echo "$bat %" if [[ "$bat" = 100 ]] then