diff options
author | Johannes Löthberg <johannes@kyriasis.com> | 2017-06-01 18:59:02 +0200 |
---|---|---|
committer | Johannes Löthberg <johannes@kyriasis.com> | 2017-06-01 18:59:02 +0200 |
commit | 1b9ca04faeb9db9c078b13c7fcf89b20fd8257d9 (patch) | |
tree | 73b2b347bdd8ddf5c634c13cb4e4e8f3afa05424 | |
parent | 9d5290a4f62476190c25dc0c2a64f86e45f37dbb (diff) | |
download | dotfiles-1b9ca04faeb9db9c078b13c7fcf89b20fd8257d9.tar.xz |
i3: bar: add hydrogen battery config
Signed-off-by: Johannes Löthberg <johannes@kyriasis.com>
-rw-r--r-- | i3/bar.py | 45 |
1 files changed, 34 insertions, 11 deletions
@@ -11,17 +11,40 @@ status.register("clock", format="%y-%m-%d %H:%M:%S%z",) -status.register("battery", - format="⚡:{percentage:.2f}% {remaining:%E%hh:%Mm}{status}", - alert=True, - alert_percentage=5, - status={ - "DIS": "↓", - "CHR": "↑", - "FULL": "=", - }, - battery_ident="BAT0",) - +if hostname == "hydrogen.kyriasis.com": + status.register("battery", + format="⚡0:{percentage:.2f}% {remaining:%E%hh:%Mm}{status}", + alert=True, + alert_percentage=5, + status={ + "DIS": "↓", + "CHR": "↑", + "FULL": "=", + }, + battery_ident="BAT0",) + + status.register("battery", + format="⚡1:{percentage:.2f}% {remaining:%E%hh:%Mm}{status}", + alert=True, + alert_percentage=5, + status={ + "DIS": "↓", + "CHR": "↑", + "FULL": "=", + }, + battery_ident="BAT1",) + +else: + status.register("battery", + format="⚡:{percentage:.2f}% {remaining:%E%hh:%Mm}{status}", + alert=True, + alert_percentage=5, + status={ + "DIS": "↓", + "CHR": "↑", + "FULL": "=", + }, + battery_ident="BAT0",) status.register("temp", format="{temp:.0f}°C",) |