diff options
author | Benno Fünfstück <benno.fuenfstueck@gmail.com> | 2014-06-28 20:33:28 +0200 |
---|---|---|
committer | Benno Fünfstück <benno.fuenfstueck@gmail.com> | 2014-06-28 21:06:10 +0200 |
commit | e10001042d6fc2b4246f51b5fa1625b8bf7e8df3 (patch) | |
tree | f01e3e8ab58fb4474dc16df523257def2d05771f /pkgs/build-support | |
parent | 9b7dbcc83e2b8c8fcb37bc204bba83311e17eca0 (diff) | |
download | nixpkgs-e10001042d6fc2b4246f51b5fa1625b8bf7e8df3.tar nixpkgs-e10001042d6fc2b4246f51b5fa1625b8bf7e8df3.tar.gz nixpkgs-e10001042d6fc2b4246f51b5fa1625b8bf7e8df3.tar.bz2 nixpkgs-e10001042d6fc2b4246f51b5fa1625b8bf7e8df3.tar.lz nixpkgs-e10001042d6fc2b4246f51b5fa1625b8bf7e8df3.tar.xz nixpkgs-e10001042d6fc2b4246f51b5fa1625b8bf7e8df3.tar.zst nixpkgs-e10001042d6fc2b4246f51b5fa1625b8bf7e8df3.zip |
fetchbzr, fetchdarcs, fetchhg: use `rev` attr
This makes it match the behaviour of fetchgit and fetchsvn, so it's easier to write scripts that support all of them.
Diffstat (limited to 'pkgs/build-support')
-rw-r--r-- | pkgs/build-support/fetchbzr/builder.sh | 4 | ||||
-rw-r--r-- | pkgs/build-support/fetchbzr/default.nix | 4 | ||||
-rw-r--r-- | pkgs/build-support/fetchdarcs/builder.sh | 6 | ||||
-rw-r--r-- | pkgs/build-support/fetchdarcs/default.nix | 4 | ||||
-rw-r--r-- | pkgs/build-support/fetchhg/builder.sh | 4 | ||||
-rw-r--r-- | pkgs/build-support/fetchhg/default.nix | 4 |
6 files changed, 13 insertions, 13 deletions
diff --git a/pkgs/build-support/fetchbzr/builder.sh b/pkgs/build-support/fetchbzr/builder.sh index 17567fdadd2..af1257d3688 100644 --- a/pkgs/build-support/fetchbzr/builder.sh +++ b/pkgs/build-support/fetchbzr/builder.sh @@ -1,9 +1,9 @@ source "$stdenv/setup" -header "exporting \`$url' (revision $revision) into \`$out'" +header "exporting \`$url' (revision $rev) into \`$out'" # Perform a lightweight checkout so that we don't end up importing # all the repository's history. -bzr -Ossl.cert_reqs=none export -r "$revision" --format=dir "$out" "$url" +bzr -Ossl.cert_reqs=none export -r "$rev" --format=dir "$out" "$url" stopNest diff --git a/pkgs/build-support/fetchbzr/default.nix b/pkgs/build-support/fetchbzr/default.nix index 721250beeb3..dd2c0363187 100644 --- a/pkgs/build-support/fetchbzr/default.nix +++ b/pkgs/build-support/fetchbzr/default.nix @@ -1,5 +1,5 @@ { stdenv, bazaar }: -{ url, revision, sha256 }: +{ url, rev, sha256 }: stdenv.mkDerivation { name = "bzr-export"; @@ -11,5 +11,5 @@ stdenv.mkDerivation { outputHashMode = "recursive"; outputHash = sha256; - inherit url revision; + inherit url rev; } diff --git a/pkgs/build-support/fetchdarcs/builder.sh b/pkgs/build-support/fetchdarcs/builder.sh index efff5ff5ebf..301deb98307 100644 --- a/pkgs/build-support/fetchdarcs/builder.sh +++ b/pkgs/build-support/fetchdarcs/builder.sh @@ -2,9 +2,9 @@ source $stdenv/setup tagtext="" tagflags="" -if test -n "$tag"; then - tagtext="(tag $tag) " - tagflags="--tag=$tag" +if test -n "$rev"; then + tagtext="(tag $rev) " + tagflags="--tag=$rev" elif test -n "$context"; then tagtext="(context) " tagflags="--context=$context" diff --git a/pkgs/build-support/fetchdarcs/default.nix b/pkgs/build-support/fetchdarcs/default.nix index 63e4ecde88a..3c2e0524eea 100644 --- a/pkgs/build-support/fetchdarcs/default.nix +++ b/pkgs/build-support/fetchdarcs/default.nix @@ -1,4 +1,4 @@ -{stdenv, darcs, nix}: {url, tag ? null, context ? null, md5 ? "", sha256 ? ""}: +{stdenv, darcs, nix}: {url, rev ? null, context ? null, md5 ? "", sha256 ? ""}: stdenv.mkDerivation { name = "fetchdarcs"; @@ -9,5 +9,5 @@ stdenv.mkDerivation { outputHashMode = "recursive"; outputHash = if sha256 == "" then md5 else sha256; - inherit url tag context; + inherit url rev context; } diff --git a/pkgs/build-support/fetchhg/builder.sh b/pkgs/build-support/fetchhg/builder.sh index 9699fb69b7f..0b51ef79b23 100644 --- a/pkgs/build-support/fetchhg/builder.sh +++ b/pkgs/build-support/fetchhg/builder.sh @@ -1,9 +1,9 @@ source $stdenv/setup -header "getting $url${tag:+ ($tag)} into $out" +header "getting $url${rev:+ ($rev)} into $out" hg clone --insecure "$url" hg-clone -hg archive -q -y ${tag:+-r "$tag"} --cwd hg-clone $out +hg archive -q -y ${rev:+-r "$rev"} --cwd hg-clone $out rm -f $out/.hg_archival.txt stopNest diff --git a/pkgs/build-support/fetchhg/default.nix b/pkgs/build-support/fetchhg/default.nix index 1aebb7ecc87..4675cbe6ec8 100644 --- a/pkgs/build-support/fetchhg/default.nix +++ b/pkgs/build-support/fetchhg/default.nix @@ -1,4 +1,4 @@ -{stdenv, mercurial, nix}: {name ? null, url, tag ? null, md5 ? null, sha256 ? null}: +{stdenv, mercurial, nix}: {name ? null, url, rev ? null, md5 ? null, sha256 ? null}: # TODO: statically check if mercurial as the https support if the url starts woth https. stdenv.mkDerivation { @@ -13,6 +13,6 @@ stdenv.mkDerivation { outputHashMode = "recursive"; outputHash = if md5 != null then md5 else sha256; - inherit url tag; + inherit url rev; preferLocalBuild = true; } |