Commit e4ae69da authored by Glen Mével's avatar Glen Mével

fix acpi parsing in `battery-monitor.sh`

parent e70c26c5
......@@ -47,7 +47,8 @@ while true ; do
output=( $(acpi) )
status="${output[2]%,}"
percentage="${output[3]%\%,}"
percentage="${output[3]%,}"
percentage="${percentage%\%}"
# Battery becomes charging, or charged enough.
if [ "$state" -lt 3 -a \( "$status" != 'Discharging' -o "$percentage" -gt "$THRESHOLD_LOW" \) ] ; then
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment