summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Stapelberg <michael@stapelberg.de>2009-12-13 13:59:59 +0100
committerMichael Stapelberg <michael@stapelberg.de>2009-12-13 13:59:59 +0100
commit9307ff9d131a70164a50e57e3aa3115c92715925 (patch)
tree4c93ccd7a4b3e74faf07dc53fc4cded644fe7add
parent58e0b05eb95afc6c67fd44ef8691ff8812a7c40a (diff)
The load values represent 1,5,15 min, not 5,10,15 min (Thanks Chris)
-rw-r--r--i3status.conf2
-rw-r--r--src/print_load.c8
2 files changed, 5 insertions, 5 deletions
diff --git a/i3status.conf b/i3status.conf
index 1e120cf..774aa06 100644
--- a/i3status.conf
+++ b/i3status.conf
@@ -42,7 +42,7 @@ time {
}
load {
- format = "%5min"
+ format = "%1min"
}
cpu_temperature 0 {
diff --git a/src/print_load.c b/src/print_load.c
index c0d9494..9fe1964 100644
--- a/src/print_load.c
+++ b/src/print_load.c
@@ -20,14 +20,14 @@ void print_load(const char *format) {
continue;
}
- if (BEGINS_WITH(walk+1, "5min")) {
+ if (BEGINS_WITH(walk+1, "1min")) {
(void)printf("%1.2f", loadavg[0]);
- walk += strlen("5min");
+ walk += strlen("1min");
}
- if (BEGINS_WITH(walk+1, "10min")) {
+ if (BEGINS_WITH(walk+1, "5min")) {
(void)printf("%1.2f", loadavg[1]);
- walk += strlen("10min");
+ walk += strlen("5min");
}
if (BEGINS_WITH(walk+1, "15min")) {