about summary refs log tree commit diff
path: root/pkgs/dwm
diff options
context:
space:
mode:
authorPatryk Niedźwiedziński <pniedzwiedzinski19@gmail.com>2020-09-07 19:42:19 +0200
committerPatryk Niedźwiedziński <pniedzwiedzinski19@gmail.com>2020-09-07 19:42:19 +0200
commite8333cd06e5007509601e804a052a85ebb8a2f04 (patch)
tree3f3e6cd1539137f16478df6ad975670585c19f92 /pkgs/dwm
parent3e1625e77a4cea39b1b7593906f934d500959ea6 (diff)
downloadpnpkgs-e8333cd06e5007509601e804a052a85ebb8a2f04.tar.gz
pnpkgs-e8333cd06e5007509601e804a052a85ebb8a2f04.zip
Add telegram shortcut
Diffstat (limited to 'pkgs/dwm')
-rw-r--r--pkgs/dwm/default.nix5
-rw-r--r--pkgs/dwm/dwm-telegram.diff13
2 files changed, 15 insertions, 3 deletions
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} },