nixos-rebuild-ng: don't try to register the profile when doing build or test
This commit is contained in:
committed by
Thiago Kenji Okada
parent
d34056b218
commit
debea81ba7
@@ -322,12 +322,13 @@ def execute(argv: list[str]) -> None:
|
||||
from_host=build_host,
|
||||
**copy_flags,
|
||||
)
|
||||
nix.set_profile(
|
||||
profile,
|
||||
path_to_config,
|
||||
target_host=target_host,
|
||||
sudo=args.sudo,
|
||||
)
|
||||
if action in (Action.SWITCH, Action.BOOT):
|
||||
nix.set_profile(
|
||||
profile,
|
||||
path_to_config,
|
||||
target_host=target_host,
|
||||
sudo=args.sudo,
|
||||
)
|
||||
if action in (Action.SWITCH, Action.BOOT, Action.TEST, Action.DRY_ACTIVATE):
|
||||
nix.switch_to_configuration(
|
||||
path_to_config,
|
||||
|
||||
Reference in New Issue
Block a user