Have battery status only show in menu bar when running on battery power

I use my MacBook Pro plugged in to power and an external monitor 90% of the time, and thus the little charged battery indicator in the menubar is useless. However when I'm not on wall power, is there a way to have it show up? When I have that menu item disabled, my MacBook doesn't give me any low battery warnings, and just shuts down (it's happened several times).


Solution 1:

I use SlimBatteryMonitor (free, donations accepted, not nagware) instead of the default menu item for the battery status.

SBM can be configured to almost disappear from the menu bar when fully charged.

If that isn't enough for you, you could run a launchd script every few minutes to check the status of the battery, to see whether or not it is fully charged, and act accordingly:

  • If the battery is fully charged, quit SlimBatteryMonitor (if it is running)

  • If the battery is NOT fully charged, run SlimBatteryMonitor (if it isn't already running)

I am actually doing something like this already. I just uploaded the necessary files to https://github.com/tjluoma/slimbatterymonitor