diff options
author | Weijia Wang <9713184+wegank@users.noreply.github.com> | 2024-04-13 19:10:53 +0200 |
---|---|---|
committer | Weijia Wang <9713184+wegank@users.noreply.github.com> | 2024-04-13 19:10:53 +0200 |
commit | f3a1652b098bbe33e5ab8a827ff3778b3c2120b8 (patch) | |
tree | 243f5d1e82706ad3d727a26692bd1d53d9373776 /lib | |
parent | 561b7b74f8e5783f29bb589482b3ed60ce2c1318 (diff) | |
parent | c0c2f2903f310dd5efb86f02b4b5f824183f5173 (diff) |
Merge branch 'master' into staging-next
Diffstat (limited to 'lib')
-rw-r--r-- | lib/default.nix | 2 | ||||
-rw-r--r-- | lib/modules.nix | 8 | ||||
-rw-r--r-- | lib/options.nix | 6 |
3 files changed, 9 insertions, 7 deletions
diff --git a/lib/default.nix b/lib/default.nix index 21e4bab2b942b..c77ce88cc4403 100644 --- a/lib/default.nix +++ b/lib/default.nix @@ -146,7 +146,7 @@ let scrubOptionValue literalExpression literalExample showOption showOptionWithDefLocs showFiles unknownModule mkOption mkPackageOption mkPackageOptionMD - mdDoc literalMD; + literalMD; inherit (self.types) isType setType defaultTypeMerge defaultFunctor isOptionType mkOptionType; inherit (self.asserts) diff --git a/lib/modules.nix b/lib/modules.nix index 17bc1f1d76647..79892f50c4fe2 100644 --- a/lib/modules.nix +++ b/lib/modules.nix @@ -136,7 +136,7 @@ let # TODO: Change the type of this option to a submodule with a # freeformType, so that individual arguments can be documented # separately - description = lib.mdDoc '' + description = '' Additional arguments passed to each module in addition to ones like `lib`, `config`, and `pkgs`, `modulesPath`. @@ -187,14 +187,14 @@ let type = types.bool; internal = true; default = true; - description = lib.mdDoc "Whether to check whether all option definitions have matching declarations."; + description = "Whether to check whether all option definitions have matching declarations."; }; _module.freeformType = mkOption { type = types.nullOr types.optionType; internal = true; default = null; - description = lib.mdDoc '' + description = '' If set, merge all definitions that don't have an associated option together using this type. The result then gets combined with the values of all declared options to produce the final ` @@ -209,7 +209,7 @@ let _module.specialArgs = mkOption { readOnly = true; internal = true; - description = lib.mdDoc '' + description = '' Externally provided module arguments that can't be modified from within a configuration, but can be used in module imports. ''; diff --git a/lib/options.nix b/lib/options.nix index 0d1d90efe2179..a968bb77d4c9c 100644 --- a/lib/options.nix +++ b/lib/options.nix @@ -400,9 +400,11 @@ rec { literalExample = lib.warn "lib.literalExample is deprecated, use lib.literalExpression instead, or use lib.literalMD for a non-Nix description." literalExpression; /* Transition marker for documentation that's already migrated to markdown - syntax. This is a no-op and no longer needed. + syntax. Has been a no-op for some while and been removed from nixpkgs. + Kept here to alert downstream users who may not be aware of the migration's + completion that it should be removed from modules. */ - mdDoc = lib.id; + mdDoc = lib.warn "lib.mdDoc was removed from nixpkgs. Option descriptions are now in Markdown by default, you can remove any remaining uses of it."; /* For use in the `defaultText` and `example` option attributes. Causes the given MD text to be inserted verbatim in the documentation, for when |