From e8333cd06e5007509601e804a052a85ebb8a2f04 Mon Sep 17 00:00:00 2001 From: Patryk Niedźwiedziński Date: Mon, 7 Sep 2020 19:42:19 +0200 Subject: Add telegram shortcut --- pkgs/dwm/default.nix | 5 ++--- pkgs/dwm/dwm-telegram.diff | 13 +++++++++++++ 2 files changed, 15 insertions(+), 3 deletions(-) create mode 100644 pkgs/dwm/dwm-telegram.diff (limited to 'pkgs/dwm') diff --git a/pkgs/dwm/default.nix b/pkgs/dwm/default.nix index 67b5c64..aa7ca15 100644 --- a/pkgs/dwm/default.nix +++ b/pkgs/dwm/default.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchgit, libX11, libXinerama, libXft, patches ? [] }: +{ stdenv, fetchgit, libX11, libXinerama, libXft }: with stdenv.lib; @@ -15,8 +15,7 @@ stdenv.mkDerivation rec { prePatch = ''sed -i "s@/usr/local@$out@" config.mk''; - # Allow users set their own list of patches - inherit patches; + patches = [ ./dwm-telegram.diff ]; buildPhase = " make "; diff --git a/pkgs/dwm/dwm-telegram.diff b/pkgs/dwm/dwm-telegram.diff new file mode 100644 index 0000000..5dca1a8 --- /dev/null +++ b/pkgs/dwm/dwm-telegram.diff @@ -0,0 +1,13 @@ +diff --git a/config.h b/config.h +index 771e7a1..d8fd17c 100644 +--- a/config.h ++++ b/config.h +@@ -154,7 +154,7 @@ static Key keys[] = { + { MODKEY|ShiftMask, XK_bracketleft, spawn, SHCMD("mpc seek -60") }, + { MODKEY, XK_bracketright, spawn, SHCMD("mpc seek +10") }, + { MODKEY|ShiftMask, XK_bracketright, spawn, SHCMD("mpc seek +60") }, +- { MODKEY, XK_backslash, view, {0} }, ++ { MODKEY, XK_backslash, spawn, SHCMD("telegram-desktop") }, + /* { MODKEY|ShiftMask, XK_backslash, spawn, SHCMD("") }, */ + + { MODKEY, XK_a, togglegaps, {0} }, -- cgit 1.4.1