mirror of
https://github.com/CHN-beta/nixpkgs.git
synced 2026-01-11 18:32:23 +08:00
lib/options: Add hint for debugging infinite recursion in docs
This commit is contained in:
@@ -242,6 +242,8 @@ rec {
|
||||
in if ss != {} then optionAttrSetToDocList' opt.loc ss else [];
|
||||
subOptionsVisible = docOption.visible && opt.visible or null != "shallow";
|
||||
in
|
||||
# To find infinite recursion in NixOS option docs:
|
||||
# builtins.trace opt.loc
|
||||
[ docOption ] ++ optionals subOptionsVisible subOptions) (collect isOption options);
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user