diff options
author | Silvan Mosberger <contact@infinisil.com> | 2019-12-10 02:51:19 +0100 |
---|---|---|
committer | Silvan Mosberger <contact@infinisil.com> | 2019-12-10 02:51:19 +0100 |
commit | 4ee3e8b21dfeaf236b86a0c109953dd809a77e64 (patch) | |
tree | 79bf61d3635aa336cd88d215470be66f489cc267 /nixos/modules/misc | |
parent | cd9ace689274fedd7e95dabdc99041d4c799c3dc (diff) |
nixos/treewide: Move rename.nix imports to their respective modules
A centralized list for these renames is not good because:
- It breaks disabledModules for modules that have a rename defined
- Adding/removing renames for a module means having to find them in the
central file
- Merge conflicts due to multiple people editing the central file
Diffstat (limited to 'nixos/modules/misc')
-rw-r--r-- | nixos/modules/misc/documentation.nix | 5 | ||||
-rw-r--r-- | nixos/modules/misc/locate.nix | 5 | ||||
-rw-r--r-- | nixos/modules/misc/version.nix | 6 |
3 files changed, 16 insertions, 0 deletions
diff --git a/nixos/modules/misc/documentation.nix b/nixos/modules/misc/documentation.nix index deecb005270f..820553270e3b 100644 --- a/nixos/modules/misc/documentation.nix +++ b/nixos/modules/misc/documentation.nix @@ -67,6 +67,11 @@ let in { + imports = [ + (mkRenamedOptionModule [ "programs" "info" "enable" ] [ "documentation" "info" "enable" ]) + (mkRenamedOptionModule [ "programs" "man" "enable" ] [ "documentation" "man" "enable" ]) + (mkRenamedOptionModule [ "services" "nixosManual" "enable" ] [ "documentation" "nixos" "enable" ]) + ]; options = { diff --git a/nixos/modules/misc/locate.nix b/nixos/modules/misc/locate.nix index 737ed5c0a3f6..552535c253e6 100644 --- a/nixos/modules/misc/locate.nix +++ b/nixos/modules/misc/locate.nix @@ -7,6 +7,11 @@ let isMLocate = hasPrefix "mlocate" cfg.locate.name; isFindutils = hasPrefix "findutils" cfg.locate.name; in { + imports = [ + (mkRenamedOptionModule [ "services" "locate" "period" ] [ "services" "locate" "interval" ]) + (mkRemovedOptionModule [ "services" "locate" "includeStore" ] "Use services.locate.prunePaths" ) + ]; + options.services.locate = with types; { enable = mkOption { type = bool; diff --git a/nixos/modules/misc/version.nix b/nixos/modules/misc/version.nix index cf17f9aae38b..0540b493003f 100644 --- a/nixos/modules/misc/version.nix +++ b/nixos/modules/misc/version.nix @@ -10,6 +10,12 @@ let in { + imports = [ + (mkRenamedOptionModule [ "system" "nixosVersion" ] [ "system" "nixos" "version" ]) + (mkRenamedOptionModule [ "system" "nixosVersionSuffix" ] [ "system" "nixos" "versionSuffix" ]) + (mkRenamedOptionModule [ "system" "nixosRevision" ] [ "system" "nixos" "revision" ]) + (mkRenamedOptionModule [ "system" "nixosLabel" ] [ "system" "nixos" "label" ]) + ]; options.system = { |