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.
This commit is contained in:
@@ -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"
|
||||
|
||||
@@ -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;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user