forked from ashish-yadav11/dwmblocks
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathblocks.h
38 lines (28 loc) · 2.17 KB
/
blocks.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
/* time interval in seconds to sleep before looking for updates in the main loop */
#define SLEEPINTERVAL 1
#define PATH(name) "/home/athul/.local/projects/dwmblocks/blocks/"name
/* If interval of a block is set to 0, the block will only be updated once at startup.
* If interval is set to a negative value, the block will never be updated in the main loop.
* Set pathc to NULL if clickability is not required for the block.
* Set signal to 0 if both clickability and signaling are not required for the block.
* Signal must be less than 10 for clickable blocks.
* If multiple signals are pending, then the lowest numbered one will be delivered first. */
/* pathu - path of the program whose output is to be used for status text
* output of the program should have a null or newline character at the end
* pathc - path of the program to be executed on clicks */
static Block blocks[] = {
/* pathu pathc interval signal */
{ PATH("vpn.sh"), NULL, 4, 8},
{ PATH("spotify.sh"), PATH("spotify_button.sh"), 0, 5},
{ PATH("cpu_usage.sh"), NULL, 5, 6},
{ PATH("memory.sh"), PATH("memory_button.sh"), 5, 3},
{ PATH("netraff.sh"), NULL, 1, 0},
{ PATH("volume.sh"), PATH("volume_button.sh"), 1, 1},
/* { PATH("cpu_temp.sh"), PATH("cpu_temp_button.sh"), 1, 4},*/
{ PATH("battery.sh"), PATH("battery_button.sh"), 3, 4},
{ PATH("datetime.sh"), NULL, 30, 0},
{ PATH("bluetooth.sh"), PATH("bluetooth_button.sh"), 5, 7},
{ PATH("internet.sh"), PATH("internet_button.sh"), 10, 2},
{ NULL } /* just to mark the end of the array */
};
static const char *delim = " ";