bat.sh 178 B

1234567891011
  1. #!/bin/sh
  2. while true
  3. do
  4. battery_percentage=$(cat /sys/class/power_supply/axp20x-battery/capacity)
  5. time=$(date +%I:%M)
  6. echo " $battery_percentage%  $time "
  7. sleep 10
  8. done