2006-02-25 21:36:53 +03:00
|
|
|
#!/bin/sh
|
|
|
|
# periodically print date and load average to the bar
|
|
|
|
|
|
|
|
xwrite() {
|
|
|
|
file="$1"; shift
|
|
|
|
echo -n "$@" | wmiir write "$file"
|
|
|
|
}
|
|
|
|
|
2006-03-23 13:03:43 +03:00
|
|
|
wmiir remove /bar/status 2>/dev/null && sleep 2
|
2006-03-09 04:15:43 +03:00
|
|
|
wmiir create /bar/status
|
2006-03-26 18:48:49 +04:00
|
|
|
xwrite /bar/status/colors $WMII_NORMCOLORS
|
2006-02-25 21:36:53 +03:00
|
|
|
|
2006-03-09 14:00:47 +03:00
|
|
|
while xwrite /bar/status/data `date` `uptime | sed 's/.*://; s/,//g'`
|
2006-02-25 21:36:53 +03:00
|
|
|
do
|
2006-03-01 14:06:19 +03:00
|
|
|
sleep 1
|
2006-02-25 21:36:53 +03:00
|
|
|
done
|