lib/modules: Add syntactic sugar for config._module.freeformType
This introduces `freeformType` as a top-level module attribute, allowing
definitions like
{
freeformType = ...;
options = ...;
config = ...;
}
This commit is contained in:
@@ -1,3 +1,3 @@
|
||||
{ lib, ... }: {
|
||||
config._module.freeformType = with lib.types; attrsOf (either str (attrsOf str));
|
||||
freeformType = with lib.types; attrsOf (either str (attrsOf str));
|
||||
}
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
{ lib, ... }: {
|
||||
config._module.freeformType = with lib.types; lazyAttrsOf (either str (lazyAttrsOf str));
|
||||
freeformType = with lib.types; lazyAttrsOf (either str (lazyAttrsOf str));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user