mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-17 23:36:17 +01:00
Merge pull request #26358 from LnL7/fetchgit-postfetch
fetchgit: add postFetch argument
This commit is contained in:
commit
ee22e3de08
2 changed files with 5 additions and 1 deletions
|
@ -12,4 +12,5 @@ $SHELL $fetcher --builder --url "$url" --out "$out" --rev "$rev" \
|
||||||
${fetchSubmodules:+--fetch-submodules} \
|
${fetchSubmodules:+--fetch-submodules} \
|
||||||
${branchName:+--branch-name "$branchName"}
|
${branchName:+--branch-name "$branchName"}
|
||||||
|
|
||||||
|
runHook postFetch
|
||||||
stopNest
|
stopNest
|
||||||
|
|
|
@ -15,6 +15,9 @@ in
|
||||||
, fetchSubmodules ? true, deepClone ? false
|
, fetchSubmodules ? true, deepClone ? false
|
||||||
, branchName ? null
|
, branchName ? null
|
||||||
, name ? urlToName url rev
|
, name ? urlToName url rev
|
||||||
|
, # Shell code executed after the file has been fetched
|
||||||
|
# successfully. This can do things like check or transform the file.
|
||||||
|
postFetch ? ""
|
||||||
}:
|
}:
|
||||||
|
|
||||||
/* NOTE:
|
/* NOTE:
|
||||||
|
@ -54,7 +57,7 @@ stdenv.mkDerivation {
|
||||||
outputHashMode = "recursive";
|
outputHashMode = "recursive";
|
||||||
outputHash = sha256;
|
outputHash = sha256;
|
||||||
|
|
||||||
inherit url rev leaveDotGit fetchSubmodules deepClone branchName;
|
inherit url rev leaveDotGit fetchSubmodules deepClone branchName postFetch;
|
||||||
|
|
||||||
GIT_SSL_CAINFO = "${cacert}/etc/ssl/certs/ca-bundle.crt";
|
GIT_SSL_CAINFO = "${cacert}/etc/ssl/certs/ca-bundle.crt";
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue