From d2df553da17e38eb73fde1ebcb1664ebe80ddd62 Mon Sep 17 00:00:00 2001 From: aszlig Date: Fri, 19 Jun 2015 18:50:08 +0200 Subject: [PATCH] fetchpatch: Allow to pass a postFetch attribute. Comes in handy if we want to make additional modificiations to the output file. While I wasn't sure whether to invoke the passed postFetch directly before the patch or afterwards, I thought it would be better afterwards because "postFetch of fetchpatch" at least to my intuition would sound that after whatever "fetchpatch" does - it comes afterwards. Signed-off-by: aszlig --- pkgs/build-support/fetchpatch/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/pkgs/build-support/fetchpatch/default.nix b/pkgs/build-support/fetchpatch/default.nix index 29ff5c31e45..60785f42b54 100644 --- a/pkgs/build-support/fetchpatch/default.nix +++ b/pkgs/build-support/fetchpatch/default.nix @@ -18,5 +18,6 @@ fetchurl ({ --strip=${toString stripLen} \ --clean "$out" > "$tmpfile" mv "$tmpfile" "$out" + ${args.postFetch or ""} ''; } // builtins.removeAttrs args ["stripLen"])