flake: place builds strictly in build/ directory
This commit is contained in:
@@ -280,8 +280,8 @@
|
|||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
nix build ".#nixosConfigurations.$host.config.system.build.toplevel" --out-link "./result-$host" "$@"
|
nix build ".#nixosConfigurations.$host.config.system.build.toplevel" --out-link "./build/result-$host" "$@"
|
||||||
storePath="$(readlink ./result-$host)"
|
storePath="$(readlink ./build/result-$host)"
|
||||||
|
|
||||||
# mimic `nixos-rebuild --target-host`, in effect:
|
# mimic `nixos-rebuild --target-host`, in effect:
|
||||||
# - nix-copy-closure ...
|
# - nix-copy-closure ...
|
||||||
@@ -541,7 +541,7 @@
|
|||||||
checkHost = host: let
|
checkHost = host: let
|
||||||
shellHost = pkgs.lib.replaceStrings [ "-" ] [ "_" ] host;
|
shellHost = pkgs.lib.replaceStrings [ "-" ] [ "_" ] host;
|
||||||
in ''
|
in ''
|
||||||
nix build -v '.#nixosConfigurations.${host}.config.system.build.toplevel' --out-link ./result-${host} -j2 "$@"
|
nix build -v '.#nixosConfigurations.${host}.config.system.build.toplevel' --out-link ./build/result-${host} -j2 "$@"
|
||||||
RC_${shellHost}=$?
|
RC_${shellHost}=$?
|
||||||
'';
|
'';
|
||||||
in builtins.toString (pkgs.writeShellScript
|
in builtins.toString (pkgs.writeShellScript
|
||||||
@@ -590,7 +590,7 @@
|
|||||||
check.rescue = {
|
check.rescue = {
|
||||||
type = "app";
|
type = "app";
|
||||||
program = builtins.toString (pkgs.writeShellScript "check-rescue" ''
|
program = builtins.toString (pkgs.writeShellScript "check-rescue" ''
|
||||||
nix build -v '.#imgs.rescue' --out-link ./result-rescue-img -j2
|
nix build -v '.#imgs.rescue' --out-link ./build/result-rescue-img -j2
|
||||||
'');
|
'');
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user