Commit 80cafd06 authored by nicoo's avatar nicoo
Browse files

fetchRepoProject: support `hash` attribute, wrapping in `withnormalizedHash`

parent ac177dff
Loading
Loading
Loading
Loading
+82 −82
Original line number Diff line number Diff line
{ lib, stdenvNoCC, gitRepo, cacert, copyPathsToStore }:

{ name, manifest, rev ? "HEAD", sha256
lib.fetchers.withNormalizedHash { } (
  { name, manifest, rev ? "HEAD", outputHash, outputHashAlgo
  # Optional parameters:
  , repoRepoURL ? "", repoRepoRev ? "", referenceDir ? "", manifestName ? ""
  , localManifests ? [], createMirror ? false, useArchive ? false
@@ -39,9 +39,8 @@ in stdenvNoCC.mkDerivation {

    inherit cacert manifest rev repoRepoURL repoRepoRev referenceDir; # TODO

  outputHashAlgo = "sha256";
    inherit outputHash outputHashAlgo;
    outputHashMode = "recursive";
  outputHash = sha256;

    preferLocalBuild = true;
    enableParallelBuilding = true;
@@ -81,3 +80,4 @@ in stdenvNoCC.mkDerivation {
      ''}
    '';
  }
)