This commit is contained in:
Rob Vermaas
2011-03-17 13:25:27 +00:00
parent 10e10e8a8c
commit 9f33d4c98d
17 changed files with 85 additions and 22 deletions

View File

@ -1,22 +1,20 @@
with import ./config.nix;
{
empty_dir =
derivation {
mkDerivation {
name = "empty-dir";
system = builtins.currentSystem;
builder = ./empty-dir-builder.sh;
};
fails =
derivation {
mkDerivation {
name = "fails";
system = builtins.currentSystem;
builder = ./fail.sh;
};
succeed_with_failed =
derivation {
mkDerivation {
name = "succeed-with-failed";
system = builtins.currentSystem;
builder = ./succeed-with-failed.sh;
};
}

View File

@ -0,0 +1,18 @@
with import ./config.nix;
let
jobs = {
build1 =
mkDerivation {
name = "build1";
builder = ./empty-dir-builder.sh;
};
build2 =
{build1 ? jobs.build1 }:
mkDerivation {
name = "build2";
builder = ./empty-dir-builder.sh;
inherit build1;
};
};
in jobs

View File

@ -1,9 +1,10 @@
with import ./config.nix;
{ src }:
{
copy =
derivation {
mkDerivation {
name = "bzr-checkout-input";
system = builtins.currentSystem;
builder = ./scm-builder.sh;
inherit src;
};
}

View File

@ -1,9 +1,10 @@
with import ./config.nix;
{ src }:
{
copy =
derivation {
mkDerivation {
name = "bzr-input";
system = builtins.currentSystem;
builder = ./scm-builder.sh;
inherit src;
};
}

9
tests/jobs/config.nix.in Normal file
View File

@ -0,0 +1,9 @@
rec {
path = "@testPath@";
mkDerivation = args:
derivation ({
system = builtins.currentSystem;
PATH = path;
} // args);
}

View File

@ -1 +1,3 @@
#! /bin/sh
mkdir $out

View File

@ -1 +1,2 @@
#! /bin/sh
exit 1

View File

@ -1,9 +1,10 @@
with import ./config.nix;
{ src }:
{
copy =
derivation {
mkDerivation {
name = "git-input";
system = builtins.currentSystem;
builder = ./scm-builder.sh;
inherit src;
};
}

View File

@ -1,9 +1,10 @@
with import ./config.nix;
{ src }:
{
copy =
derivation {
mkDerivation {
name = "hg-input";
system = builtins.currentSystem;
builder = ./scm-builder.sh;
inherit src;
};
}

View File

@ -1,2 +1,3 @@
#! /bin/sh
mkdir $out
cp -v $src/* $out/

View File

@ -1,2 +1,3 @@
#! /bin/sh
mkdir -p $out/nix-support/failed

View File

@ -1,9 +1,10 @@
with import ./config.nix;
{ src }:
{
copy =
derivation {
mkDerivation {
name = "bzr-checkout-input";
system = builtins.currentSystem;
builder = ./scm-builder.sh;
inherit src;
};
}

View File

@ -1,9 +1,10 @@
with import ./config.nix;
{ src }:
{
copy =
derivation {
mkDerivation {
name = "svn-input";
system = builtins.currentSystem;
builder = ./scm-builder.sh;
inherit src;
};
}