diff options
| author | Marc Vertes <mvertes@free.fr> | 2023-02-17 16:16:56 +0100 |
|---|---|---|
| committer | Marc Vertes <mvertes@free.fr> | 2023-02-17 16:16:56 +0100 |
| commit | c8fb9352ac79d2ccf3dcdb352840b60e4dcc548a (patch) | |
| tree | 6ad28f31e5d8673ab3a6180e46ff2cf87a28e767 | |
| parent | fe0415e0b2ec50c866c5d2f297bce112abf6d690 (diff) | |
add batt to print battery status
| -rwxr-xr-x | bin/batt | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/bin/batt b/bin/batt new file mode 100755 index 0000000..a5eb22f --- /dev/null +++ b/bin/batt @@ -0,0 +1,4 @@ +#!/bin/sh +# print battery status +. /sys/class/power_supply/BAT0/uevent && +echo "$POWER_SUPPLY_TYPE $POWER_SUPPLY_STATUS $POWER_SUPPLY_CAPACITY%" |
