From 84968c9b91bff8d25701d67b3fde4ed8e0540931 Mon Sep 17 00:00:00 2001 From: Valentin Gehrke Date: Wed, 10 Jun 2015 08:43:17 +0200 Subject: [PATCH] Small error in pkginfo.sh + added updates to bar.sh again --- scripts/bar.sh | 7 ++++--- scripts/pkginfo.sh | 2 +- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/scripts/bar.sh b/scripts/bar.sh index 72b6ff0..2da07d7 100755 --- a/scripts/bar.sh +++ b/scripts/bar.sh @@ -3,7 +3,7 @@ FIFO="/tmp/bar.fifo" FORMAT_LEFT=" %(music)s %(services)s %(diskspace)s" -FORMAT_RIGHT="%(wifi)s %(battery)s %(clock)s " +FORMAT_RIGHT="%(updates)s %(wifi)s %(battery)s %(clock)s " icon_color="#A0A57E" icon() { echo -n "%{F$icon_color}"; printf '%b' "\ue$1"; echo -n "%{F-}"; } @@ -113,8 +113,8 @@ clock() { updates() { while true; do - updates=$(pkginfo.sh) - echo -n "$icon_updates $updates" + updates=$(./pkginfo.sh) + echo updates "$icon_updates $updates" > $FIFO; sleep 20 done } @@ -146,6 +146,7 @@ music & services & diskspace & wifi & +updates & ( while true; do cat $FIFO; done ) | python ./barformatter.py "$FORMAT_LEFT" "$FORMAT_RIGHT" | lemonbar -g 1366x15 -f "Stlarch:size=6:style=regular" -f "Terminus:size=8" -B "#88000000" | run_handler diff --git a/scripts/pkginfo.sh b/scripts/pkginfo.sh index e521be3..5c77340 100755 --- a/scripts/pkginfo.sh +++ b/scripts/pkginfo.sh @@ -14,7 +14,7 @@ useless_packages() { pacman -Qtdq | wc -l } -if [ -Z "$internet" ]; then +if [ -z "$internet" ]; then pac=? aur=? else