nixos/nix-channel: only try to remove the nix-channel binary if it exists

It may not be there if `system.disableInstallerTools = true`.
This commit is contained in:
r-vdp 2023-07-23 15:33:50 +02:00
parent 668e2dafb6
commit b825f65c90
No known key found for this signature in database

View File

@ -86,7 +86,7 @@ in
'';
environment.extraSetup = mkIf (!cfg.channel.enable) ''
rm $out/bin/nix-channel
rm --force $out/bin/nix-channel
'';
# NIX_PATH has a non-empty default according to Nix docs, so we don't unset