From 54cd3434980e3f0d5869a1ce92fdc5577603c9bc Mon Sep 17 00:00:00 2001
From: Valentin Gehrke <madmaurice@zom.bi>
Date: Mon, 8 Jun 2015 09:24:22 +0200
Subject: [PATCH] Less cache time for checkupdates

---
 scripts/bar.sh | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/scripts/bar.sh b/scripts/bar.sh
index a5c3541..ccca271 100755
--- a/scripts/bar.sh
+++ b/scripts/bar.sh
@@ -49,7 +49,7 @@ services() {
 }
 
 diskspace() {
-    info=$(df -h / | awk '{if($6 == "/") { print $5 }}')
+    info=$(./cmdcache.sh 10 "df -h /" | awk '{if($6 == "/") { print $5 }}')
     echo -n "%{A:I "filesystem 30":}$icon_diskspace $info%{A}"
 }
 
@@ -62,7 +62,7 @@ wifi() {
 }
 
 battery() {
-    level=$(acpi -b | awk -F, 'BEGIN { s=0 } { s+=$2 } END { print int(s/NR) }')
+    level=$(./cmdcache.sh 5 "acpi -b" | awk -F, 'BEGIN { s=0 } { s+=$2 } END { print int(s/NR) }')
     charging=$(acpi -a | grep on-line)
 
     icon=$icon_battery
@@ -83,7 +83,7 @@ clock() {
 }
 
 updates() {
-    info=$(./cmdcache.sh 1200 checkupdates | wc -l)
+    info=$(./cmdcache.sh 20 checkupdates | wc -l)
     echo -n "$icon_updates $info"
 }