eval.nix: Suppress _module.args docs

This commit is contained in:
Zhaofeng Li 2022-05-22 02:15:33 -07:00
parent 838a200854
commit 429a0f5aa1

View file

@ -135,8 +135,7 @@ let
in evalConfig { in evalConfig {
inherit (npkgs) system; inherit (npkgs) system;
modules = let modules = [
in [
nixpkgsModule nixpkgsModule
colmenaModules.assertionModule colmenaModules.assertionModule
colmenaModules.keyChownModule colmenaModules.keyChownModule
@ -191,6 +190,14 @@ let
inherit nixpkgs lib; inherit nixpkgs lib;
nodes = uncheckedNodes; nodes = uncheckedNodes;
}; };
suppressModuleArgsDocs = { lib, ... }: {
options = {
_module.args = lib.mkOption {
internal = true;
};
};
};
in { in {
inherit inherit
nodes toplevel nodes toplevel
@ -204,7 +211,7 @@ in {
docs = { docs = {
deploymentOptions = pkgs: let deploymentOptions = pkgs: let
eval = pkgs.lib.evalModules { eval = pkgs.lib.evalModules {
modules = [ colmenaOptions.deploymentOptions ]; modules = [ colmenaOptions.deploymentOptions suppressModuleArgsDocs ];
specialArgs = { specialArgs = {
name = "nixos"; name = "nixos";
nodes = {}; nodes = {};
@ -214,7 +221,7 @@ in {
metaOptions = pkgs: let metaOptions = pkgs: let
eval = pkgs.lib.evalModules { eval = pkgs.lib.evalModules {
modules = [ colmenaOptions.metaOptions ]; modules = [ colmenaOptions.metaOptions suppressModuleArgsDocs ];
}; };
in eval.options; in eval.options;
}; };