mirror of
https://github.com/SebastianWendel/nixpkgs.git
synced 2024-09-20 12:29:02 +02:00
Add `fetchbzr', to retrieve remote Bazaar repositories.
svn path=/nixpkgs/trunk/; revision=12924
This commit is contained in:
parent
3a9d5063bd
commit
9383cd0a48
9
pkgs/build-support/fetchbzr/builder.sh
Normal file
9
pkgs/build-support/fetchbzr/builder.sh
Normal file
|
@ -0,0 +1,9 @@
|
|||
source "$stdenv/setup"
|
||||
|
||||
header "exporting \`$url' (revision $revision) into \`$out'"
|
||||
|
||||
# Perform a lightweight checkout so that we don't end up importing
|
||||
# all the repository's history.
|
||||
bzr checkout --lightweight "$url" -r "$revision" "$out"
|
||||
|
||||
stopNest
|
15
pkgs/build-support/fetchbzr/default.nix
Normal file
15
pkgs/build-support/fetchbzr/default.nix
Normal file
|
@ -0,0 +1,15 @@
|
|||
{ stdenv, bazaar }:
|
||||
{ url, revision, sha256 }:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "bzr-export";
|
||||
|
||||
builder = ./builder.sh;
|
||||
buildInputs = [ bazaar ];
|
||||
|
||||
outputHashAlgo = "sha256";
|
||||
outputHashMode = "recursive";
|
||||
outputHash = sha256;
|
||||
|
||||
inherit url revision;
|
||||
}
|
|
@ -353,6 +353,10 @@ let
|
|||
inherit fetchurl stdenv;
|
||||
};
|
||||
|
||||
fetchbzr = import ../build-support/fetchbzr {
|
||||
inherit stdenv bazaar;
|
||||
};
|
||||
|
||||
fetchcvs = import ../build-support/fetchcvs {
|
||||
inherit stdenv cvs;
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue