This commit is contained in:
Nox Sluijtman 2024-06-23 09:26:57 +02:00
parent 1a32129e41
commit af67f9d3df
Signed by: Egg
SSH key fingerprint: SHA256:2sG9X3C7Xvq2svGumz1/k7cm8l4G9+qAtAeugqB4J9M

View file

@ -6,10 +6,7 @@ def main [
--push-to-machine(-p) # Whether or not to push the result to the given machine
--print-build-logs(-L) # Print full build logs on standard error.
command # 'nixos-rebuild' command to execute
#...misc # misc parameters
] {
let flake = $".#($machine)"
let buildOnMachine = if $build_on_machine {
$"--build-host ($machine)"
}
@ -25,10 +22,11 @@ def main [
let command = [
"nixos-rebuild"
$command
$printBuildLogs
$buildOnMachine
$"--flake .#($machine)"
$pushToMachine
$printBuildLogs
] | filter {|| $in | is-not-empty} | str join " "
^bash -c $command
}