dotfiles/polybar/config.ini

180 lines
5.5 KiB
INI
Raw Normal View History

2023-05-21 17:10:54 +02:00
;==========================================================
;
;==========================================================
; Include powerline utility
include-file = ~/.config/polybar/powerline-for-polybar.config
; Include color scheme
include-file = ~/.config/polybar/colors.config
;=======================================
; Bar
;=======================================
[bar/example]
; Generic options
width = 100%
height = 26
dpi-x = 96
dpi-y = 96
2023-05-21 18:57:39 +02:00
tray-position = right
tray-background = ${colors.blue}
2023-05-21 20:30:22 +02:00
tray-offset-x = -4
tray-padding = 7
2023-05-21 18:57:39 +02:00
2023-05-21 17:10:54 +02:00
; Set bar's default background/foreground color
2023-05-21 20:30:22 +02:00
background = #9912151c
2023-05-21 17:10:54 +02:00
foreground = ${colors.white}
; Set bar's fonts list
2023-05-21 18:57:39 +02:00
font-0 = "Noto Sans:size=10.5:antialias=true;3"
2023-05-21 17:10:54 +02:00
font-1 = "Source Code Pro:pixelsize=20:antialias=true;6"
2023-05-21 18:57:39 +02:00
font-2 = "Source Code Pro:size=11:weight=bold:antialias=true;3"
font-3 = "Font Awesome 6 Free Solid:size=11:antialias=true;3"
font-4 = "Font Awesome 6 Free:size=11:antialias=true;3"
font-5 = "Font Awesome 6 Brands:size=11:antialias=true;3"
font-6 = "Font Awesome v4 Compatibility:size=11:antialias=true;3"
2023-05-21 17:10:54 +02:00
; Set modules list
modules-left = xwindow
modules-center = i3
2023-05-21 18:57:39 +02:00
modules-right = date governor temperature memory clockspeed cpu pulseaudio battery startarrow
2023-05-21 17:10:54 +02:00
fixed-center = true
;=======================================
; Modules
;=======================================
2023-05-21 18:57:39 +02:00
[module/startarrow]
inherit = powerline-modules/right-to-left-starting-arrow
background = ${colors.blue}
background-next = ${colors.background}
2023-05-21 17:10:54 +02:00
[module/pulseaudio]
type = internal/pulseaudio
inherit = powerline-templates/right-to-left-item
background = ${colors.blue}
2023-05-21 18:57:39 +02:00
background-next = ${colors.background}
2023-05-21 17:10:54 +02:00
label-muted-foreground = ${colors.gray}
format-foreground = ${colors.white}
format-volume-background = ${colors.blue}
format-muted-background = ${colors.blue}
2023-05-21 18:57:39 +02:00
format-volume = " <ramp-volume> <label-volume> "
2023-05-21 20:30:22 +02:00
format-muted = "  <label-volume> "
2023-05-21 18:57:39 +02:00
ramp-volume-0 = 🔈
ramp-volume-1 = 🔊
2023-05-21 17:10:54 +02:00
[module/date]
; Powerline settings
inherit = powerline-templates/right-to-left-item
background = ${colors.blue}
2023-05-21 18:57:39 +02:00
background-next = ${root.background}
2023-05-21 17:10:54 +02:00
; Other settings
type = internal/date
format-background = ${self.background}
format-foreground = ${colors.white}
2023-05-21 20:30:22 +02:00
date = " %a %b %d, %H:%M:%S "
2023-05-21 17:10:54 +02:00
[module/cpu]
; Powerline settings
inherit = powerline-templates/right-to-left-item
background = ${colors.background}
background-next = ${colors.blue}
; Other settings
type = internal/cpu
format-background = ${self.background}
format-foreground = ${colors.white}
2023-05-21 18:57:39 +02:00
label = " CPU %percentage%% "
2023-05-21 17:10:54 +02:00
[module/memory]
; Powerline settings
inherit = powerline-templates/right-to-left-item
2023-05-21 18:57:39 +02:00
background = ${colors.background}
background-next = ${colors.blue}
; Other settings
type = internal/memory
format-background = ${self.background}
format-foreground = ${colors.white}
label = " %gb_used% "
[module/clockspeed]
; Powerline settings
inherit = powerline-templates/right-to-left-item
2023-05-21 17:10:54 +02:00
background = ${colors.blue}
background-next = ${colors.background}
; Other settings
2023-05-21 18:57:39 +02:00
type = custom/script
2023-05-21 17:10:54 +02:00
format-background = ${self.background}
format-foreground = ${colors.white}
2023-05-21 18:57:39 +02:00
format-warn-background = ${self.background}
exec = cat /proc/cpuinfo | grep MHz | cut -b 12- | sort -r | head -n 1 | xargs printf '%f / 1000\\n' | bc -l | awk '{printf "%.2f\\n", $0}'
format = " <label> GHz "
2023-05-21 17:10:54 +02:00
[module/temperature]
; Powerline settings
inherit = powerline-templates/right-to-left-item
2023-05-21 18:57:39 +02:00
background = ${colors.blue}
background-next = ${colors.background}
; Other settings
type = custom/script
format-background = ${colors.blue}
format-foreground = ${colors.white}
format-warn-background = ${self.background}
exec = sensors | grep Package | cut -d ' ' -f 5 | cut -d '+' -f 2
format = " <label> "
[module/governor]
; Powerline settings
inherit = powerline-templates/right-to-left-item
2023-05-21 17:10:54 +02:00
background = ${colors.background}
background-next = ${colors.blue}
; Other settings
2023-05-21 18:57:39 +02:00
type = custom/script
2023-05-21 17:10:54 +02:00
format-background = ${self.background}
format-foreground = ${colors.white}
2023-05-21 18:57:39 +02:00
format-warn-background = ${self.background}
exec = cat /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
format = " <label> "
click-left = /home/user/.config/awesome/scripts/toggle_performance.sh
2023-05-21 17:10:54 +02:00
[module/xwindow]
; Other settings
type = internal/xwindow
inherit = powerline-templates/left-to-right-item
background = ${colors.blue}
background-next = ${root.background}
format-background = ${self.background}
format-foreground = ${colors.white}
2023-05-21 20:30:22 +02:00
label = "  %title% "
label-maxlen = 80
2023-05-21 17:10:54 +02:00
[module/i3]
type = internal/i3
pin-workspaces = true
show-urgent = true
index-sort = true
enable-click = true
label-unfocused-padding = 3
label-focused-background = ${colors.blue}
label-focused-padding = 3
label-focused-font=3
label-unfocused-font=3
label-separator-padding = 2
label-focused = %index%
label-unfocused = %index%
2023-05-21 20:30:22 +02:00
label-mode = %mode%
label-mode-padding = 3
label-mode-background = ${colors.blue}
2023-05-21 18:57:39 +02:00
[module/battery]
type = custom/script
inherit = powerline-templates/right-to-left-item
background = ${colors.background}
background-next = ${colors.blue}
format-background = ${self.background}
format-foreground = ${colors.white}
exec = upower -i /org/freedesktop/UPower/devices/battery_BAT1 | ag percentage | awk '{print $2}'
format = " <label>  "