From b8060bf715f6e2505d10d48b96c231fc94fb08dc Mon Sep 17 00:00:00 2001 From: Jason Miller Date: Tue, 8 Mar 2022 19:03:39 -0800 Subject: [PATCH] notmuch-bower: Add runtime dependencies Bower shells out to several programs, but only two that I could find are not runtime configurable; "file" for determining mime types and base64 for base64 encoding. This replaces the shell invocations with the Nix versions of these programs respectively --- .../networking/mailreaders/notmuch-bower/default.nix | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/pkgs/applications/networking/mailreaders/notmuch-bower/default.nix b/pkgs/applications/networking/mailreaders/notmuch-bower/default.nix index 235991396f57..79b553a5dc92 100644 --- a/pkgs/applications/networking/mailreaders/notmuch-bower/default.nix +++ b/pkgs/applications/networking/mailreaders/notmuch-bower/default.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, fetchFromGitHub, mercury, pandoc, ncurses, gpgme }: +{ lib, stdenv, fetchFromGitHub, mercury, pandoc, ncurses, gpgme, coreutils, file }: stdenv.mkDerivation rec { pname = "notmuch-bower"; @@ -12,6 +12,10 @@ stdenv.mkDerivation rec { }; nativeBuildInputs = [ mercury pandoc ]; + postPatch = '' + substituteInPlace src/compose.m --replace 'shell_quoted("base64' 'shell_quoted("${coreutils}/bin/base64' + substituteInPlace src/detect_mime_type.m --replace 'shell_quoted("file' 'shell_quoted("${file}/bin/file' + ''; buildInputs = [ ncurses gpgme ];