aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--components/battery.obin0 -> 5152 bytes
-rw-r--r--components/cat.obin0 -> 2104 bytes
-rw-r--r--components/cpu.obin0 -> 3112 bytes
-rw-r--r--components/datetime.obin0 -> 1944 bytes
-rw-r--r--components/disk.obin0 -> 3120 bytes
-rw-r--r--components/entropy.obin0 -> 1800 bytes
-rw-r--r--components/hostname.obin0 -> 1656 bytes
-rw-r--r--components/ip.obin0 -> 3104 bytes
-rw-r--r--components/kernel_release.obin0 -> 1832 bytes
-rw-r--r--components/keyboard_indicators.obin0 -> 2416 bytes
-rw-r--r--components/keymap.obin0 -> 4016 bytes
-rw-r--r--components/load_avg.obin0 -> 1864 bytes
-rw-r--r--components/netspeeds.obin0 -> 2760 bytes
-rw-r--r--components/num_files.obin0 -> 2112 bytes
-rw-r--r--components/ram.obin0 -> 3072 bytes
-rw-r--r--components/run_command.obin0 -> 2120 bytes
-rw-r--r--components/swap.obin0 -> 3880 bytes
-rw-r--r--components/temperature.obin0 -> 1720 bytes
-rw-r--r--components/uptime.obin0 -> 1968 bytes
-rw-r--r--components/user.obin0 -> 2192 bytes
-rw-r--r--components/volume.obin0 -> 3584 bytes
-rw-r--r--components/wifi.obin0 -> 5920 bytes
-rw-r--r--config.h72
23 files changed, 72 insertions, 0 deletions
diff --git a/components/battery.o b/components/battery.o
new file mode 100644
index 0000000..3deff79
--- /dev/null
+++ b/components/battery.o
Binary files differ
diff --git a/components/cat.o b/components/cat.o
new file mode 100644
index 0000000..6c3820d
--- /dev/null
+++ b/components/cat.o
Binary files differ
diff --git a/components/cpu.o b/components/cpu.o
new file mode 100644
index 0000000..8e1bfc1
--- /dev/null
+++ b/components/cpu.o
Binary files differ
diff --git a/components/datetime.o b/components/datetime.o
new file mode 100644
index 0000000..225a048
--- /dev/null
+++ b/components/datetime.o
Binary files differ
diff --git a/components/disk.o b/components/disk.o
new file mode 100644
index 0000000..f3bd7bd
--- /dev/null
+++ b/components/disk.o
Binary files differ
diff --git a/components/entropy.o b/components/entropy.o
new file mode 100644
index 0000000..53d9b82
--- /dev/null
+++ b/components/entropy.o
Binary files differ
diff --git a/components/hostname.o b/components/hostname.o
new file mode 100644
index 0000000..e678e25
--- /dev/null
+++ b/components/hostname.o
Binary files differ
diff --git a/components/ip.o b/components/ip.o
new file mode 100644
index 0000000..ef0faf7
--- /dev/null
+++ b/components/ip.o
Binary files differ
diff --git a/components/kernel_release.o b/components/kernel_release.o
new file mode 100644
index 0000000..207785e
--- /dev/null
+++ b/components/kernel_release.o
Binary files differ
diff --git a/components/keyboard_indicators.o b/components/keyboard_indicators.o
new file mode 100644
index 0000000..5542fb2
--- /dev/null
+++ b/components/keyboard_indicators.o
Binary files differ
diff --git a/components/keymap.o b/components/keymap.o
new file mode 100644
index 0000000..d565c9a
--- /dev/null
+++ b/components/keymap.o
Binary files differ
diff --git a/components/load_avg.o b/components/load_avg.o
new file mode 100644
index 0000000..3be39fc
--- /dev/null
+++ b/components/load_avg.o
Binary files differ
diff --git a/components/netspeeds.o b/components/netspeeds.o
new file mode 100644
index 0000000..9d8e32c
--- /dev/null
+++ b/components/netspeeds.o
Binary files differ
diff --git a/components/num_files.o b/components/num_files.o
new file mode 100644
index 0000000..b18b49e
--- /dev/null
+++ b/components/num_files.o
Binary files differ
diff --git a/components/ram.o b/components/ram.o
new file mode 100644
index 0000000..55c1c63
--- /dev/null
+++ b/components/ram.o
Binary files differ
diff --git a/components/run_command.o b/components/run_command.o
new file mode 100644
index 0000000..1499323
--- /dev/null
+++ b/components/run_command.o
Binary files differ
diff --git a/components/swap.o b/components/swap.o
new file mode 100644
index 0000000..b5cf1d7
--- /dev/null
+++ b/components/swap.o
Binary files differ
diff --git a/components/temperature.o b/components/temperature.o
new file mode 100644
index 0000000..0a95a28
--- /dev/null
+++ b/components/temperature.o
Binary files differ
diff --git a/components/uptime.o b/components/uptime.o
new file mode 100644
index 0000000..61f6704
--- /dev/null
+++ b/components/uptime.o
Binary files differ
diff --git a/components/user.o b/components/user.o
new file mode 100644
index 0000000..7e2240e
--- /dev/null
+++ b/components/user.o
Binary files differ
diff --git a/components/volume.o b/components/volume.o
new file mode 100644
index 0000000..9328f11
--- /dev/null
+++ b/components/volume.o
Binary files differ
diff --git a/components/wifi.o b/components/wifi.o
new file mode 100644
index 0000000..4d63335
--- /dev/null
+++ b/components/wifi.o
Binary files differ
diff --git a/config.h b/config.h
new file mode 100644
index 0000000..2c19979
--- /dev/null
+++ b/config.h
@@ -0,0 +1,72 @@
+/* See LICENSE file for copyright and license details. */
+
+/* interval between updates (in ms) */
+const unsigned int interval = 1000;
+
+/* text to show if no value can be retrieved */
+static const char unknown_str[] = "n/a";
+
+/* maximum output string length */
+#define MAXLEN 2048
+
+/*
+ * function description argument (example)
+ *
+ * battery_perc battery percentage battery name (BAT0)
+ * NULL on OpenBSD/FreeBSD
+ * battery_remaining battery remaining HH:MM battery name (BAT0)
+ * NULL on OpenBSD/FreeBSD
+ * battery_state battery charging state battery name (BAT0)
+ * NULL on OpenBSD/FreeBSD
+ * cat read arbitrary file path
+ * cpu_freq cpu frequency in MHz NULL
+ * cpu_perc cpu usage in percent NULL
+ * datetime date and time format string (%F %T)
+ * disk_free free disk space in GB mountpoint path (/)
+ * disk_perc disk usage in percent mountpoint path (/)
+ * disk_total total disk space in GB mountpoint path (/)
+ * disk_used used disk space in GB mountpoint path (/)
+ * entropy available entropy NULL
+ * gid GID of current user NULL
+ * hostname hostname NULL
+ * ipv4 IPv4 address interface name (eth0)
+ * ipv6 IPv6 address interface name (eth0)
+ * kernel_release `uname -r` NULL
+ * keyboard_indicators caps/num lock indicators format string (c?n?)
+ * see keyboard_indicators.c
+ * keymap layout (variant) of current NULL
+ * keymap
+ * load_avg load average NULL
+ * netspeed_rx receive network speed interface name (wlan0)
+ * netspeed_tx transfer network speed interface name (wlan0)
+ * num_files number of files in a directory path
+ * (/home/foo/Inbox/cur)
+ * ram_free free memory in GB NULL
+ * ram_perc memory usage in percent NULL
+ * ram_total total memory size in GB NULL
+ * ram_used used memory in GB NULL
+ * run_command custom shell command command (echo foo)
+ * swap_free free swap in GB NULL
+ * swap_perc swap usage in percent NULL
+ * swap_total total swap size in GB NULL
+ * swap_used used swap in GB NULL
+ * temp temperature in degree celsius sensor file
+ * (/sys/class/thermal/...)
+ * NULL on OpenBSD
+ * thermal zone on FreeBSD
+ * (tz0, tz1, etc.)
+ * uid UID of current user NULL
+ * uptime system uptime NULL
+ * username username of current user NULL
+ * vol_perc OSS/ALSA volume in percent mixer file (/dev/mixer)
+ * NULL on OpenBSD/FreeBSD
+ * wifi_essid WiFi ESSID interface name (wlan0)
+ * wifi_perc WiFi signal in percent interface name (wlan0)
+ */
+static const struct arg args[] = {
+ /* function format argument */
+ { battery_remaining, "%s", "BAT0"},
+ { battery_state, " %s", "BAT0"},
+ { battery_perc, " %s%%", "BAT0" },
+ { datetime, " | %s", "%a %d-%m %T" },
+};