tmux-plugins / tmux-battery

Plug and play battery percentage and icon indicator for Tmux.
MIT License
503 stars 98 forks source link

batt_icon_status_charged /_charging, .._discharching: #97

Closed m1027 closed 4 years ago

m1027 commented 4 years ago

Thanks for the great battery plugin.

When I try to follow the description to set the battery icon like this:

set -g @batt_icon_status_charged '=' set -g @batt_icon_status_charging '+' set -g @batt_icon_status_discharging '-'

then this does not seem to be applied: #{battery_icon} continues to show a square that diminishes while power goes away.

I might miss something trivial.

rux616 commented 4 years ago

The logic behind #{battery_icon} isn't very clear in the readme, and I apologize for that.

Basically, when you use #{battery_icon}, if the battery is discharging, you will see the equivalent of #{battery_icon_charge}, and when the battery is in any other status, you will see the equivalent of #{battery_icon_status}.

So if you want only 'status'-type icons, i.e., charging/charged/discharging/etc., You should use #{battery_icon_status}.

m1027 commented 4 years ago

Great, got it working! Thanks again!