Polybar: Add dpkg lock indicator

This commit is contained in:
Salt 2018-09-15 12:35:04 -05:00
parent 8c0ca0a414
commit 79d710f064

View File

@ -25,6 +25,8 @@ icon-network = ${xrdb:color14}
icon-wm = ${xrdb:color12}
icon-xbacklight = ${res/colors.primary}
notif-package = ${self.foreground-dark}
background = ${xrdb:background}
background-alt = ${xrdb:color8}
foreground = ${xrdb:color15}
@ -86,7 +88,7 @@ inherit = template/bar
border-top-size = 0
modules-left = ${env:PB_BAR_PRIMARY_MODULES_LEFT:battery cpu memory}
modules-left = ${env:PB_BAR_PRIMARY_MODULES_LEFT:battery cpu memory dpkg}
modules-center = ${env:PB_BAR_PRIMARY_MODULES_CENTER: bspwm}
modules-right = ${env:PB_BAR_PRIMARY_MODULES_RIGHT:xbacklight volume date}
@ -142,8 +144,19 @@ content-background = ${res/colors.border}
type = custom/text
content = " "
# NOTIFICATION
#====================
[module/dpkg]
type = custom/script
format = <label>
format-foreground = ${res/colors.notif-package}
interval = 1
exec = printf "DPKG\n"
exec-if = [ -f /var/lib/dpkg/lock ]
# OTHER
#====================
[module/battery]
type = internal/battery
format-charging = <label-charging>