diff options
author | Joursoir <chat@joursoir.net> | 2022-06-17 15:58:13 +0300 |
---|---|---|
committer | Joursoir <chat@joursoir.net> | 2022-06-17 15:58:13 +0300 |
commit | e4bc737af92267d070d8c98b2fc4a86a686ad798 (patch) | |
tree | a7e537d4955bfedd71a8d7bf794ae81f23cf1deb /dotconfig/polybar/modules | |
parent | 117901947196342262b9b7c4985db67d521e73bb (diff) | |
download | dotfiles-e4bc737af92267d070d8c98b2fc4a86a686ad798.tar.gz dotfiles-e4bc737af92267d070d8c98b2fc4a86a686ad798.tar.bz2 dotfiles-e4bc737af92267d070d8c98b2fc4a86a686ad798.zip |
dotconfig/polybar: add a battery module
Diffstat (limited to 'dotconfig/polybar/modules')
-rw-r--r-- | dotconfig/polybar/modules | 94 |
1 files changed, 94 insertions, 0 deletions
diff --git a/dotconfig/polybar/modules b/dotconfig/polybar/modules index 2de20c1..1455a33 100644 --- a/dotconfig/polybar/modules +++ b/dotconfig/polybar/modules @@ -57,6 +57,100 @@ ; Right click click-right = pavucontrol +[module/battery] + type = internal/battery + + ; This is useful in case the battery never reports 100% charge + full-at = 99 + + ; Use the following command to list batteries and adapters: + ; $ ls -1 /sys/class/power_supply/ + battery = BAT1 + adapter = ACAD + + ; If an inotify event haven't been reported in this many + ; seconds, manually poll for new values. + ; + ; Needed as a fallback for systems that don't report events + ; on sysfs/procfs. + ; + ; Disable polling by setting the interval to 0. + poll-interval = 5 + + ; see "man date" for details on how to format the time string + ; NOTE: if you want to use syntax tags here you need to use %%{...} + time-format = %H:%M + + ; Available tags: + ; <label-charging> (default) + ; <bar-capacity> + ; <ramp-capacity> + ; <animation-charging> + format-charging = <label-charging> + format-charging-prefix = + format-charging-prefix-background = ${color.green} + format-charging-prefix-padding = 1 + format-charging-overline = ${color.background} + format-charging-underline = ${color.background} + + ; Available tags: + ; <label-discharging> (default) + ; <bar-capacity> + ; <ramp-capacity> + ; <animation-discharging> + format-discharging = <ramp-capacity><label-discharging> + format-discharging-overline = ${color.background} + format-discharging-underline = ${color.background} + + ; Available tags: + ; <label-full> (default) + ; <bar-capacity> + ; <ramp-capacity> + format-full = <label-full> + format-full-prefix = + format-full-prefix-background = ${color.red} + format-full-prefix-padding = 1 + format-full-overline = ${color.background} + format-full-underline = ${color.background} + + ; Available tokens: + ; %percentage% (default) + ; %time% + ; %consumption% (shows current charge rate in watts) + label-charging = %percentage%% + label-charging-background = ${color.background-alt} + label-charging-padding = 1 + + ; Available tokens: + ; %percentage% (default) + ; %time% + ; %consumption% (shows current discharge rate in watts) + label-discharging = %percentage%% + label-discharging-background = ${color.background-alt} + label-discharging-padding = 1 + + ; Available tokens: + ; %percentage% (default) + label-full = Full + label-full-background = ${color.background-alt} + label-full-padding = 1 + + ; Only applies if <ramp-capacity> is used + ramp-capacity-0 = + ramp-capacity-1 = + ramp-capacity-2 = + ramp-capacity-3 = + ramp-capacity-4 = + ramp-capacity-background = ${color.pink} + ramp-capacity-padding = 1 + + ; Only applies if <animation-charging> is used + animation-charging-0 = + animation-charging-1 = + + ; Framerate in milliseconds + animation-charging-framerate = 750 + [module/date] type = internal/date |