mirror of
https://github.com/0intro/wmii
synced 2024-11-26 15:49:37 +03:00
15 lines
293 B
Bash
15 lines
293 B
Bash
#!/bin/sh
|
|
# periodically print date and load average to the bar
|
|
|
|
xwrite() {
|
|
file="$1"; shift
|
|
echo -n "$@" | wmiir write "$file"
|
|
}
|
|
|
|
wmiir remove /bar/status 2>/dev/null && sleep 2
|
|
wmiir create /bar/status
|
|
while xwrite /bar/status/data `date` `uptime | sed 's/.*://; s/,//g'`
|
|
do
|
|
sleep 1
|
|
done
|