Loading pkgs/build-support/fetchdarcs/builder.sh +17 −4 Original line number Diff line number Diff line set -u tagtext="" tagflags="" # Darcs hashes are sha1 (120 bits, 40-character hex) Loading @@ -12,8 +14,19 @@ elif test -n "$context"; then tagflags="--context=$context" fi echo "Cloning $url $partial ${tagtext} into $out" # Repository list may contain ?. No glob expansion for that. set -o noglob darcs clone --lazy $tagflags "$url" "$out" for repository in $repositories; do echo "Trying to clone $repository $tagtext into $out …" if darcs clone --lazy $tagflags "$repository" "$out"; then # remove metadata, because it can change rm -rf "$out/_darcs" exit 0 fi done set +o noglob echo "Error: couldn’t clone repository from any mirror" 1>&2 exit 1 pkgs/build-support/fetchdarcs/default.nix +6 −1 Original line number Diff line number Diff line Loading @@ -8,7 +8,11 @@ lib.makeOverridable ( lib.fetchers.withNormalizedHash { } ( { # Repository to fetch url, # Additional list of repositories specifying alternative download # location to be tried in order, if the prior repository failed to fetch. mirrors ? [ ], rev ? null, context ? null, outputHash ? lib.fakeHash, Loading @@ -27,11 +31,12 @@ lib.makeOverridable ( outputHashMode = "recursive"; inherit url rev context name ; repositories = [ url ] ++ mirrors; } ) ) Loading
pkgs/build-support/fetchdarcs/builder.sh +17 −4 Original line number Diff line number Diff line set -u tagtext="" tagflags="" # Darcs hashes are sha1 (120 bits, 40-character hex) Loading @@ -12,8 +14,19 @@ elif test -n "$context"; then tagflags="--context=$context" fi echo "Cloning $url $partial ${tagtext} into $out" # Repository list may contain ?. No glob expansion for that. set -o noglob darcs clone --lazy $tagflags "$url" "$out" for repository in $repositories; do echo "Trying to clone $repository $tagtext into $out …" if darcs clone --lazy $tagflags "$repository" "$out"; then # remove metadata, because it can change rm -rf "$out/_darcs" exit 0 fi done set +o noglob echo "Error: couldn’t clone repository from any mirror" 1>&2 exit 1
pkgs/build-support/fetchdarcs/default.nix +6 −1 Original line number Diff line number Diff line Loading @@ -8,7 +8,11 @@ lib.makeOverridable ( lib.fetchers.withNormalizedHash { } ( { # Repository to fetch url, # Additional list of repositories specifying alternative download # location to be tried in order, if the prior repository failed to fetch. mirrors ? [ ], rev ? null, context ? null, outputHash ? lib.fakeHash, Loading @@ -27,11 +31,12 @@ lib.makeOverridable ( outputHashMode = "recursive"; inherit url rev context name ; repositories = [ url ] ++ mirrors; } ) )