LeSysBot docs

Package version

1.0.0

Platforms

macOS

Requires on PATH

pmset

Python dependencies

none

Install#

Install just this package:

shell
lesysbot tools install lesysbot/lesysbot-packages-official/tools/battery

Or take the whole Official packages collection at once:

shell
lesysbot install lesysbot/lesysbot-packages-official

Tools#

This package exposes 1 tool.

battery()#

shell command

Report charge percentage, whether the Mac is on AC or battery, and the estimated time remaining.

Runs

shell
pmset -g batt

Parameters

Takes no parameters.

Notes#

  • macOS-only: a bare collection install skips it elsewhere (the OS gate is immutable); --only battery or --all overrides.
  • Needs no root and no confirmation. On a desktop Mac it reports that there are no batteries rather than failing.

Source#

Every package is a folder holding a README.md and a tool.py. Read this one on GitHub: lesysbot/lesysbot-packages-official/tools/battery.

To write your own, see Writing tools.