ci: garbage collect between host builds

This commit is contained in:
kat witch 2021-05-21 17:32:02 +01:00
parent 635706a236
commit b7f8b44f6a
No known key found for this signature in database
GPG key ID: 1B477797DCA5EC72

View file

@ -73,7 +73,7 @@ with lib; {
git -P diff nix/sources.json
nix build --no-link -Lf . sourceCache.local
echo "checking that hosts still build..." >&2
if nix build -Lf . hosts.{athame,yule,samhain}.config.system.build.toplevel; then
if nix build -Lf . hosts.athame.config.system.build.toplevel && nix-collect-garbage -d && nix build -Lf . hosts.yule.config.system.build.toplevel && nix-collect-garbage -d && nix build -Lf . hosts.samhain.config.system.build.toplevel; then
if [[ -n $CACHIX_SIGNING_KEY ]]; then
nix build --no-link -Lf . sourceCache.all
cachix push kittywitch $(nix eval --raw -f . sourceCache.allStr)