blob: 41b937b7f401e264babbe63e6c91cb33c880832b (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
|
-- let buildTemplate =
λ ( repoName
: Text
)
→ { image =
"debian/stretch"
, packages =
[ "curl" ]
, triggers =
[ { condition =
"failure"
, action =
"email"
, to =
"EuAndreh <eu@euandre.org>"
}
]
, sources =
[ "https://git.sr.ht/~euandreh/" ++ repoName ]
, secrets =
[ "7159f943-811f-402d-bb6d-37cd764dc728" ]
, tasks =
[ { mapKey =
"setup"
, mapValue =
''
curl https://nixos.org/nix/install | sh
echo '. $HOME/.nix-profile/etc/profile.d/nix.sh' >> $HOME/.buildenv''
},
{ mapKey =
"test"
, mapValue =
''
cd ${repoName}/
nix-build -A test''
},
{ mapKey =
"publish"
, mapValue =
''
cd ${repoName}/
nix-build -A publishScript
source env.sh
./result/bin/publish.sh''
}
]
}
|