From ffe00e6139e3bb367aaaa2f3f76760e314ca443d Mon Sep 17 00:00:00 2001 From: Guido Cella Date: Tue, 4 Aug 2020 06:03:44 +0200 Subject: Define SHCMD macro --- config.def.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'config.def.h') diff --git a/config.def.h b/config.def.h index 309c2fa..17b1489 100644 --- a/config.def.h +++ b/config.def.h @@ -49,6 +49,8 @@ static const int repeat_delay = 600; { MODKEY|WLR_MODIFIER_SHIFT, SKEY, tag, {.ui = 1 << TAG} }, \ { MODKEY|WLR_MODIFIER_CTRL|WLR_MODIFIER_SHIFT,SKEY,toggletag, {.ui = 1 << TAG} } +#define SHCMD(cmd) { .v = (const char*[]){ "/bin/sh", "-c", cmd, NULL } } + /* commands */ static const char *termcmd[] = { "alacritty", NULL }; -- cgit v1.2.3 From 0816b33d333e949437a465b0dcf8461ba4c099a5 Mon Sep 17 00:00:00 2001 From: "Devin J. Pohly" Date: Sun, 16 Aug 2020 01:02:01 -0500 Subject: add comment from dwm --- config.def.h | 1 + 1 file changed, 1 insertion(+) (limited to 'config.def.h') diff --git a/config.def.h b/config.def.h index eff8f59..53021cf 100644 --- a/config.def.h +++ b/config.def.h @@ -51,6 +51,7 @@ static const int repeat_delay = 600; { MODKEY|WLR_MODIFIER_SHIFT, SKEY, tag, {.ui = 1 << TAG} }, \ { MODKEY|WLR_MODIFIER_CTRL|WLR_MODIFIER_SHIFT,SKEY,toggletag, {.ui = 1 << TAG} } +/* helper for spawning shell commands in the pre dwm-5.0 fashion */ #define SHCMD(cmd) { .v = (const char*[]){ "/bin/sh", "-c", cmd, NULL } } /* commands */ -- cgit v1.2.3