slstatus

My fork of https://tools.suckless.org/slstatus/
git clone https://git.inz.fi/slstatus
Log | Files | Refs | README | LICENSE

config.def.h (4207B)


      1 /* See LICENSE file for copyright and license details. */
      2 
      3 /* interval between updates (in ms) */
      4 const unsigned int interval = 1000;
      5 
      6 /* maximum output string length */
      7 #define MAXLEN 2048
      8 
      9 /*
     10  * function            description                     argument (example)
     11  *
     12  * battery_perc        battery percentage              battery name (BAT0)
     13  *                                                     NULL on OpenBSD/FreeBSD
     14  * battery_state       battery charging state          battery name (BAT0)
     15  *                                                     NULL on OpenBSD/FreeBSD
     16  * battery_remaining   battery remaining HH:MM         battery name (BAT0)
     17  *                                                     NULL on OpenBSD/FreeBSD
     18  * cpu_perc            cpu usage in percent            NULL
     19  * cpu_freq            cpu frequency in MHz            NULL
     20  * datetime            date and time                   format string (%F %T)
     21  * disk_free           free disk space in GB           mountpoint path (/)
     22  * disk_perc           disk usage in percent           mountpoint path (/)
     23  * disk_total          total disk space in GB          mountpoint path (/")
     24  * disk_used           used disk space in GB           mountpoint path (/)
     25  * entropy             available entropy               NULL
     26  * gid                 GID of current user             NULL
     27  * hostname            hostname                        NULL
     28  * ipv4                IPv4 address                    interface name (eth0)
     29  * ipv6                IPv6 address                    interface name (eth0)
     30  * kernel_release      `uname -r`                      NULL
     31  * keyboard_indicators caps/num lock indicators        format string (c?n?)
     32  *                                                     see keyboard_indicators.c
     33  * keymap              layout (variant) of current     NULL
     34  *                     keymap
     35  * load_avg            load average                    NULL
     36  * netspeed_rx         receive network speed           interface name (wlan0)
     37  * netspeed_tx         transfer network speed          interface name (wlan0)
     38  * num_files           number of files in a directory  path
     39  *                                                     (/home/foo/Inbox/cur)
     40  * ram_free            free memory in GB               NULL
     41  * ram_perc            memory usage in percent         NULL
     42  * ram_total           total memory size in GB         NULL
     43  * ram_used            used memory in GB               NULL
     44  * run_command         custom shell command            command (echo foo)
     45  * separator           string to echo                  NULL
     46  * swap_free           free swap in GB                 NULL
     47  * swap_perc           swap usage in percent           NULL
     48  * swap_total          total swap size in GB           NULL
     49  * swap_used           used swap in GB                 NULL
     50  * temp                temperature in degree celsius   sensor file
     51  *                                                     (/sys/class/thermal/...)
     52  *                                                     NULL on OpenBSD
     53  *                                                     thermal zone on FreeBSD
     54  *                                                     (tz0, tz1, etc.)
     55  * uid                 UID of current user             NULL
     56  * uptime              system uptime                   NULL
     57  * username            username of current user        NULL
     58  * vol_perc            OSS/ALSA volume in percent      mixer file (/dev/mixer)
     59  *                                                     NULL on OpenBSD
     60  * wifi_perc           WiFi signal in percent          interface name (wlan0)
     61  * wifi_essid          WiFi ESSID                      interface name (wlan0)
     62  *
     63  * wintitle            Selected part of a window title comma separated list of
     64  *                                                     strings that must be
     65  *                                                     present in the window
     66  *                                                     title, with ! indicating
     67  *                                                     the part to capture
     68  */
     69 static const struct arg args[] = {
     70 	/* function format          argument */
     71 	{ datetime, "%s",           "%F %T" },
     72 };