Fix the statusbar battery icon

We hardcode the file path as it is now configurable
This commit is contained in:
Stacy Harper 2021-05-20 19:40:25 +02:00
parent 500a227d05
commit 200ecfa1a7
No known key found for this signature in database
GPG key ID: 5BAC92328B7C5D65

View file

@ -54,7 +54,7 @@ update() {
fi
# Battery pct
BATTERY_DEVICE="${BATTERY_DEVICE:-"/sys/class/power_supply/*-battery"}"
BATTERY_DEVICE="${BATTERY_DEVICE:-"/sys/class/power_supply/axp20x-battery"}"
PCT="$(cat "$BATTERY_DEVICE"/capacity)"
BATSTATUS="$(
cut -c1 "$BATTERY_DEVICE"/status