commit 529c1241cdd7daebce7326021d106545e5062846
parent bdf733b27d80a22a5208bc06a7ed2f153993459c
Author: Hayden Hamilton <hayden@haydenvh.com>
Date: Tue, 31 Mar 2020 13:26:34 +0100
moving to sxhkd
Diffstat:
M | config.h | | | 65 | +---------------------------------------------------------------- |
1 file changed, 1 insertion(+), 64 deletions(-)
diff --git a/config.h b/config.h
@@ -55,93 +55,30 @@ static const Layout layouts[] = {
/* helper for spawning shell commands in the pre dwm-5.0 fashion */
#define SHCMD(cmd) { .v = (const char*[]){ "/bin/sh", "-c", cmd, NULL } }
-/* commands */
static char dmenumon[2] = "0"; /* component of dmenucmd, manipulated in spawn() */
-static const char *dmenucmd[] = { "dmenu_run", NULL };
-static const char *termcmd[] = { "st", NULL };
-static const char *vimbcmd[] = { "tabbed", "-c", "vimb", "-e", NULL };
-static const char *dmpvurlcmd[] = { "dmpvurl", "/tmp/mpv-socket", "/tmp/mpv-socket2", NULL };
-static const char *rfeh_[] = { "rfeh", "images/wallpapers/", NULL };
-static const char *rfeh_left[] = { "rfeh", "images/wallpapers/", "auto", "left", NULL };
-static const char *rfeh_right[] = { "rfeh", "images/wallpapers/", "auto", "right", NULL };
-static const char *wallblur_[] = { "wallblur", NULL };
-static const char *fehffile_[] = { "fehffile", ".cache/rfeh/prev", NULL };
-static const char *rmpv_m[] = { "rmpv", "music/", "50", NULL };
-static const char *rmpv_v[] = { "rmpv", "videos/", "50", NULL };
-static const char *dmpv_m[] = { "dmpv", "music", "/tmp/mpv-socket", "/tmp/mpv-socket2", "--no-video", "fuzz", NULL };
-static const char *dmpv_v[] = { "dmpv", "videos", "/tmp/mpv-socket2", "/tmp/mpv-socket", "--fs", "fuzz", NULL };
-static const char *hmpv_back[] = { "hmpv", "back", "/tmp/mpv-socket", NULL };
-static const char *hmpv_forward[] = { "hmpv", "forward", "/tmp/mpv-socket", NULL };
-static const char *hmpv_prev[] = { "hmpv", "prev", "/tmp/mpv-socket", NULL };
-static const char *hmpv_next[] = { "hmpv", "next", "/tmp/mpv-socket", NULL };
-static const char *hmpv_toggle[] = { "hmpv", "toggle", "/tmp/mpv-socket", ";", "hmpv", "toggle", "/tmp/mpv-socket2", NULL };
-static const char *hmpv_quit[] = { "hmpv", "quit", "/tmp/mpv-socket", NULL };
-static const char *vol_up[] = { "hvol", "3.5%+", NULL };
-static const char *vol_down[] = { "hvol", "3.5%-", NULL };
-static const char *dpass_[] = { "dpass", NULL };
-static const char *slock_mod[] = { "st", "-e", "slock_mod", "/tmp/mpv-socket", "/tmp/mpv-socket2", NULL };
-static const char *cmon_[] = { "cmon", NULL };
-static const char *maim_[] = { "main", ">", "tmp.png", NULL };
-static const char *tmux_[] = { "st", "-e", "tmux", NULL };
-static const char *halt_[] = { "userinput", "\"Do you want to halt the system?\"", "\"sudo halt\"", NULL };
-static const char *reboot_[] = { "userinput", "\"Do you want to reboot the system?\"", "\"sudo reboot\"", NULL };
-static const char *suspend_[] = { "userinput", "\"Do you want to suspend the system?\"", "\"sudo zzz\"", NULL };
-static const char *hibernate_[] = { "userinput", "\"Do you want to hibernate the system?\"", "\"sudo ZZZ\"", NULL };
+static char *dmenucmd[] = { NULL };
static Key keys[] = {
/* modifier key function argument */
- /* Sys */
- { MODKEY, XK_bracketleft, spawn, {.v = suspend_ } },
- { MODKEY|ShiftMask, XK_bracketleft, spawn, {.v = hibernate_ } },
- { MODKEY|ControlMask, XK_bracketleft, spawn, {.v = halt_ } },
- { MODKEY|AltMask, XK_bracketleft, spawn, {.v = reboot_ } },
- /* Normal */
- { MODKEY, XK_Return, spawn, {.v = termcmd } },
{ MODKEY|ShiftMask, XK_Return, zoom, {0} },
{ MODKEY, XK_space, setlayout, {0} },
{ MODKEY|ShiftMask, XK_space, togglefloating, {0} },
{ MODKEY, XK_Tab, view, {0} },
- { MODKEY, XK_b, spawn, {.v = vimbcmd } },
- { MODKEY|ShiftMask, XK_b, spawn, {.v = dmpvurlcmd } },
- { MODKEY, XK_c, spawn, {.v = slock_mod } },
- { MODKEY, XK_d, spawn, {.v = dmenucmd } },
- { MODKEY, XK_e, spawn, {.v = tmux_ } },
- { MODKEY|ControlMask, XK_e, spawn, {.v = rfeh_right } },
{ MODKEY, XK_f, togglefullscr, {0} },
{ MODKEY, XK_h, setmfact, {.f = -0.05} },
{ MODKEY, XK_i, incnmaster, {.i = +1 } },
{ MODKEY, XK_j, focusstack, {.i = +1 } },
{ MODKEY, XK_k, focusstack, {.i = -1 } },
{ MODKEY, XK_l, setmfact, {.f = +0.05 } },
- { MODKEY, XK_m, spawn, {.v = cmon_ } },
{ MODKEY, XK_p, incnmaster, {.i = -1 } },
{ MODKEY, XK_q, killclient, {0} },
{ MODKEY|ShiftMask, XK_q, quit, {0} },
- { MODKEY|ControlMask, XK_q, spawn, {.v = rfeh_left } },
- { MODKEY, XK_s, spawn, {.v = dpass_ } },
- { MODKEY|ShiftMask, XK_s, spawn, {.v = maim_ } },
- { MODKEY, XK_w, spawn, {.v = rfeh_ } },
- { MODKEY|ControlMask, XK_w, spawn, {.v = wallblur_ } },
- { MODKEY|AltMask, XK_w, spawn, {.v = fehffile_ } },
{ MODKEY, XK_0, view, {.ui = ~0 } },
{ MODKEY|ShiftMask, XK_0, tag, {.ui = ~0 } },
{ MODKEY, XK_comma, focusmon, {.i = -1 } },
{ MODKEY, XK_period, focusmon, {.i = +1 } },
{ MODKEY|ShiftMask, XK_comma, tagmon, {.i = -1 } },
{ MODKEY|ShiftMask, XK_period, tagmon, {.i = +1 } },
- /* Media */
- { MODKEY|ControlMask, XK_y, spawn, {.v = dmpv_v } },
- { MODKEY|AltMask, XK_y, spawn, {.v = rmpv_v } },
- { MODKEY|ControlMask, XK_u, spawn, {.v = dmpv_m } },
- { MODKEY|AltMask, XK_u, spawn, {.v = rmpv_m } },
- { MODKEY|ControlMask, XK_i, spawn, {.v = hmpv_back } },
- { MODKEY|AltMask, XK_i, spawn, {.v = hmpv_prev } },
- { MODKEY|ControlMask, XK_o, spawn, {.v = hmpv_toggle } },
- { MODKEY|AltMask, XK_o, spawn, {.v = hmpv_quit } },
- { MODKEY|ControlMask, XK_p, spawn, {.v = hmpv_forward } },
- { MODKEY|AltMask, XK_p, spawn, {.v = hmpv_next } },
- { MODKEY|ShiftMask, XK_bracketright, spawn, {.v = vol_up } },
- { MODKEY|ShiftMask, XK_bracketright, spawn, {.v = vol_down } },
/* Layout */
{ MODKEY|AltMask, XK_1, setlayout, {.v = &layouts[0]} },
{ MODKEY|AltMask, XK_2, setlayout, {.v = &layouts[1]} },