tadd a delay configuration option - spoon - dwm status utility (2f30 fork)
(HTM) git clone git://src.adamsgaard.dk/spoon
(DIR) Log
(DIR) Files
(DIR) Refs
(DIR) LICENSE
---
(DIR) commit 29dfde42e86548d6be452186e81e05d576826165
(DIR) parent 23b147fa10024fcbc9a0353c027f0f8daa07b9ba
(HTM) Author: Quentin Rameau <quinq@fifth.space>
Date: Thu, 13 Oct 2016 13:19:28 +0200
add a delay configuration option
Diffstat:
M config.def.h | 3 +++
M spoon.c | 2 +-
2 files changed, 4 insertions(+), 1 deletion(-)
---
(DIR) diff --git a/config.def.h b/config.def.h
t@@ -1,3 +1,6 @@
+/* delay between each update in seconds */
+int delay = 1;
+
struct ent ents[] = {
/* reorder this if you want */
{ .fmt = "[%s] ", .read = mpdread },
(DIR) diff --git a/spoon.c b/spoon.c
t@@ -64,7 +64,7 @@ loop(void)
entcat(line, sizeof(line));
XStoreName(dpy, DefaultRootWindow(dpy), line);
XSync(dpy, False);
- sleep(1);
+ sleep(delay);
}
}