about summary refs log tree commit diff
path: root/modules/user/aszlig/services
diff options
context:
space:
mode:
authoraszlig <aszlig@nix.build>2018-02-01 19:34:47 +0100
committeraszlig <aszlig@nix.build>2018-02-01 22:28:24 +0100
commit9dc27c57880db6469865dc2e6aaf295665c681a3 (patch)
treeae4008e5cc5f2e8872d3174746cbf86116012415 /modules/user/aszlig/services
parent48a9fd81943482621e0745a03abc5be811a88da4 (diff)
services/i3/conky: Fix segfault
We're using "out_to_x = false" because we only want output to stdout,
unfortunately since conky version 1.10.7, this causes a segfault which
is tracked in upstream issue brndnmtthws/conky#454.

The patch I'm using here was submitted and merged upstream in
brndnmtthws/conky#455 and it's not yet part of a release yet.

Signed-off-by: aszlig <aszlig@nix.build>
Diffstat (limited to 'modules/user/aszlig/services')
-rw-r--r--modules/user/aszlig/services/i3/conky.nix11
1 files changed, 9 insertions, 2 deletions
diff --git a/modules/user/aszlig/services/i3/conky.nix b/modules/user/aszlig/services/i3/conky.nix
index 6c5815aa..b9e4c5ea 100644
--- a/modules/user/aszlig/services/i3/conky.nix
+++ b/modules/user/aszlig/services/i3/conky.nix
@@ -50,9 +50,16 @@ let
   mkConky = args: let
     time = cexpr "time" [ "%a %b %d %T %Z %Y" ];
     text = concatStringsSep " | " (args ++ singleton time);
-    conky = pkgs.conky.override {
+    conky = (pkgs.conky.override {
       weatherMetarSupport = true;
-    };
+    }).overrideAttrs (drv: {
+      # This patch fixes a segfault when using "out_to_x = false":
+      patches = (drv.patches or []) ++ singleton (pkgs.fetchpatch {
+        url = "https://github.com/brndnmtthws/conky/commit/"
+            + "562c7375883445acb58388ff16d9eb126b7e12a1.patch";
+        sha256 = "0gjb6pw0c2va0z6p0fn6nxprkwq0kp5plfdv0la8mv91ds72mmi6";
+      });
+    });
   in pkgs.writeScript "conky-run.sh" ''
     #!${pkgs.stdenv.shell}
     PATH="${pkgs.coreutils}/bin"