summaryrefslogtreecommitdiff
path: root/i3status.c
diff options
context:
space:
mode:
authorMichael Stapelberg <stapelberg@users.noreply.github.com>2015-04-02 13:42:47 -0700
committerMichael Stapelberg <stapelberg@users.noreply.github.com>2015-04-02 13:42:47 -0700
commitd00a0e087c79475e199ff33a33a3e73fcd2c0a22 (patch)
tree437e4a87d31bb8e1173c88bee00e4e8230cfc5b9 /i3status.c
parentf3ccd8ac7d9e258bda123303b1c254c6cdfd0463 (diff)
parent5c094a54932edebf6e44c4a7119fa510ddf7ae7a (diff)
Merge pull request #17 from chrko/format_down
Adding format_down option to path_exists and run_watch
Diffstat (limited to 'i3status.c')
-rw-r--r--i3status.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/i3status.c b/i3status.c
index bc8f35f..48bb59d 100644
--- a/i3status.c
+++ b/i3status.c
@@ -287,6 +287,7 @@ int main(int argc, char *argv[]) {
cfg_opt_t run_watch_opts[] = {
CFG_STR("pidfile", NULL, CFGF_NONE),
CFG_STR("format", "%title: %status", CFGF_NONE),
+ CFG_STR("format_down", NULL, CFGF_NONE),
CFG_CUSTOM_ALIGN_OPT,
CFG_CUSTOM_COLOR_OPTS,
CFG_CUSTOM_MIN_WIDTH_OPT,
@@ -295,6 +296,7 @@ int main(int argc, char *argv[]) {
cfg_opt_t path_exists_opts[] = {
CFG_STR("path", NULL, CFGF_NONE),
CFG_STR("format", "%title: %status", CFGF_NONE),
+ CFG_STR("format_down", NULL, CFGF_NONE),
CFG_CUSTOM_ALIGN_OPT,
CFG_CUSTOM_COLOR_OPTS,
CFG_CUSTOM_MIN_WIDTH_OPT,
@@ -603,13 +605,13 @@ int main(int argc, char *argv[]) {
CASE_SEC_TITLE("run_watch") {
SEC_OPEN_MAP("run_watch");
- print_run_watch(json_gen, buffer, title, cfg_getstr(sec, "pidfile"), cfg_getstr(sec, "format"));
+ print_run_watch(json_gen, buffer, title, cfg_getstr(sec, "pidfile"), cfg_getstr(sec, "format"), cfg_getstr(sec, "format_down"));
SEC_CLOSE_MAP;
}
CASE_SEC_TITLE("path_exists") {
SEC_OPEN_MAP("path_exists");
- print_path_exists(json_gen, buffer, title, cfg_getstr(sec, "path"), cfg_getstr(sec, "format"));
+ print_path_exists(json_gen, buffer, title, cfg_getstr(sec, "path"), cfg_getstr(sec, "format"), cfg_getstr(sec, "format_down"));
SEC_CLOSE_MAP;
}