diff options
author | Robert Hensing <roberth@users.noreply.github.com> | 2022-04-30 13:43:08 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-04-30 13:43:08 +0200 |
commit | c2451ed1a2ebdd25d5f6b343f2182f3457bb4cfb (patch) | |
tree | e9ab9715bef05db1642b4a6d9b1a2f8409a6f862 /lib/modules.nix | |
parent | 1cef70e82336888f897546094620416494d2083f (diff) | |
parent | 14aa201b658f43546b00153bb2ada7206ba8dd26 (diff) |
Merge pull request #167776 from hercules-ci/lib-modules-allow-disable-_modules.args-docs-internal
lib.modules: Allow making _module.args internal
Diffstat (limited to 'lib/modules.nix')
-rw-r--r-- | lib/modules.nix | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/modules.nix b/lib/modules.nix index 0b3560a126615..0bbf9d43c575e 100644 --- a/lib/modules.nix +++ b/lib/modules.nix @@ -160,7 +160,10 @@ rec { type = types.lazyAttrsOf types.raw; # Only render documentation once at the root of the option tree, # not for all individual submodules. - internal = prefix != []; + # Allow merging option decls to make this internal regardless. + ${if prefix == [] + then null # unset => visible + else "internal"} = true; # TODO: Change the type of this option to a submodule with a # freeformType, so that individual arguments can be documented # separately |