From d5d60411cd375b1e114279242f88bef6ab6f890d Mon Sep 17 00:00:00 2001 From: Salt Date: Mon, 1 Jan 2018 20:38:17 -0600 Subject: [PATCH] Polybar: Move updates to a more sensible location, add more run conditions Almost the whole damn script is in the config now --- .config/polybar/config | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.config/polybar/config b/.config/polybar/config index af19ad2c..2d654a18 100644 --- a/.config/polybar/config +++ b/.config/polybar/config @@ -79,9 +79,9 @@ font-4 = ${res/fonts.font-4} inherit = template/bar tray-position = right -modules-left = i3 bspwm | temperature-label cpu-label memory-label | xwindow-label +modules-left = i3 bspwm | temperature-label cpu-label memory-label update-arch | xwindow-label modules-center = -modules-right = | update-arch xbacklight-label volume-ramp wlan-network eth-network battery-ramp | date +modules-right = | xbacklight-label volume-ramp wlan-network eth-network battery-ramp | date [bar/gamma] inherit = template/bar @@ -407,9 +407,9 @@ label-warn-foreground = ${res/colors.alert} inherit = template/module type = custom/script exec = $HOME/.config/polybar/update-arch.sh -exec-if = wget -q --spider http://www.startpage.com/ && uname -r | grep -q "ARCH" +exec-if = wget -q --spider http://www.startpage.com/ && uname -r | grep -q "ARCH" && [ `checkupdates | wc -l` != 0 ] format-prefix = " " -format-prefix-foreground = ${res/colors.primary-dark} +format-prefix-foreground = ${res/colors.alert-dark} interval = 3600 [module/volume-ramp]