@@ -1,4 +1,4 @@
1−{stdenvNoCC, git, cacert}: let
1+{stdenvNoCC, git, git-lfs, cacert}: let
22 urlToName = url: rev: let
33 inherit (stdenvNoCC.lib) removeSuffix splitString last;
44 base = last (splitString ":" (baseNameOf (removeSuffix "/" url)));
@@ -20,6 +20,7 @@ in
2020 # successfully. This can do things like check or transform the file.
2121 postFetch ? ""
2222, preferLocalBuild ? true
23+, fetchLFS ? false
2324}:
2425
2526/* NOTE:
@@ -53,13 +54,15 @@ stdenvNoCC.mkDerivation {
5354 inherit name;
5455 builder = ./builder.sh;
5556 fetcher = ./nix-prefetch-git; # This must be a string to ensure it's called with bash.
56− nativeBuildInputs = [git];
57+
58+ nativeBuildInputs = [ git ]
59+ ++ stdenvNoCC.lib.optionals fetchLFS [ git-lfs ];
5760
5861 outputHashAlgo = "sha256";
5962 outputHashMode = "recursive";
6063 outputHash = sha256;
6164
62− inherit url rev leaveDotGit fetchSubmodules deepClone branchName postFetch;
65+ inherit url rev leaveDotGit fetchLFS fetchSubmodules deepClone branchName postFetch;
6366
6467 GIT_SSL_CAINFO = "${cacert}/etc/ssl/certs/ca-bundle.crt";
6568