pmset commands
1.0.0
Commands:
pmset-battery-full: Is the battery fully charged?pmset-battery-percent: Show the internal battery % charged.pmset-drawing: What is the power manager drawing from?pmset-drawing-ac-power: Is the system is drawing from AC power?pmset-drawing-battery-power: Is the system drawing from battery power?pmset-powerful: Is the power manager ready for powerful work?Examples:
$ pmset-battery-full && echo "yes" || echo "no"
yes
$ pmset-battery-percent
100
$ pmset-drawing
AC Power
$ pmset-drawing-ac-power && echo "yes" || echo "no"
yes
$ pmset-drawing-battery-power && echo "yes" || echo "no"
no
$ pmset-powerful && echo "yes" || echo "no"
yes