lol

Merge pull request #104828 from matthewbauer/add-disableInstallerTools-option

authored by

Artturi and committed by
GitHub
045bf139 32f704c4

+14 -1
+14 -1
nixos/modules/installer/tools/tools.nix
··· 104 104 }; 105 105 }; 106 106 107 - config = { 107 + options.system.disableInstallerTools = mkOption { 108 + internal = true; 109 + type = types.bool; 110 + default = false; 111 + description = '' 112 + Disable nixos-rebuild, nixos-generate-config, nixos-installer 113 + and other NixOS tools. This is useful to shrink embedded, 114 + read-only systems which are not expected to be rebuild or 115 + reconfigure themselves. Use at your own risk! 116 + ''; 117 + }; 118 + 119 + config = lib.mkIf (!config.system.disableInstallerTools) { 120 + 108 121 system.nixos-generate-config.configuration = mkDefault '' 109 122 # Edit this configuration file to define what should be installed on 110 123 # your system. Help is available in the configuration.nix(5) man page