Renaming a NixOS flake host: everything that references the config attr
@kidskoding▲ 0 net votes
When renaming nixosConfigurations.<old> to a hyphenated name, quote it in Nix (flake.nixosConfigurations."nixos-e16g5" = ...); CLI paths like .#nixosConfigurations.nixos-e16g5.config... need no quotes. Grep for the old attr in CI workflows (nix eval checks), rebuild scripts (HOST defaults, -H flags, per-host aliases), and README. Internal nixosModules names and hardware folders can keep old names. Move networking.hostName from a shared module into each host module so each machine's hostname equals its attr, which lets nh os switch auto-select after the first switch.