nixpkgs-suyu/pkgs/build-support/fetchdarcs/default.nix
2016-10-09 16:19:04 +02:00

14 lines
403 B
Nix

{stdenv, darcs, nix}: {url, rev ? null, context ? null, md5 ? "", sha256 ? ""}:
stdenv.mkDerivation {
name = "fetchdarcs";
builder = ./builder.sh;
buildInputs = [darcs];
outputHashAlgo = if sha256 == "" then "md5" else "sha256";
outputHashMode = "recursive";
outputHash = if sha256 == "" then
(stdenv.lib.fetchMD5warn "fetchdarcs" url md5) else sha256;
inherit url rev context;
}