summaryrefslogtreecommitdiff
path: root/include/i3status.h
diff options
context:
space:
mode:
authorMichael Stapelberg <michael@stapelberg.de>2014-12-07 15:14:02 +0100
committerMichael Stapelberg <michael@stapelberg.de>2014-12-07 15:17:31 +0100
commitb219f47f394e536198997578e4cce3c539b84b6d (patch)
tree91e7a6b489ed3dbbfc70a07b0ffa86a03512a4a4 /include/i3status.h
parent7bdfb5b72e730f2131dccd75f211aaa6d2236954 (diff)
support the special interface name _first_ for ethernet/wireless
Since we have deterministic device names in Linux, these strings are a much better default in the i3status config than "eth0" and "wlan0" (what we used before).
Diffstat (limited to 'include/i3status.h')
-rw-r--r--include/i3status.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/i3status.h b/include/i3status.h
index d816f0a..f8f0784 100644
--- a/include/i3status.h
+++ b/include/i3status.h
@@ -170,6 +170,13 @@ char *auto_detect_format();
/* src/print_time.c */
void set_timezone(const char *tz);
+/* src/first_network_device.c */
+typedef enum {
+ NET_TYPE_WIRELESS = 0,
+ NET_TYPE_ETHERNET = 1
+} net_type_t;
+const char *first_eth_interface(const net_type_t type);
+
void print_ipv6_info(yajl_gen json_gen, char *buffer, const char *format_up, const char *format_down);
void print_disk_info(yajl_gen json_gen, char *buffer, const char *path, const char *format, const char *prefix_type, const char *threshold_type, const double low_threshold);
void print_battery_info(yajl_gen json_gen, char *buffer, int number, const char *path, const char *format, const char *format_down, const char *status_chr, const char *status_bat, const char *status_full, int low_threshold, char *threshold_type, bool last_full_capacity, bool integer_battery_capacity, bool hide_seconds);