Add comments about the module system interface
Ideally the module system could be configured pretty much completely by the contents of the modules themselves, so add comments about avoiding complicating it further and possibly removing now-redundant configurability from the existing interface.
This commit is contained in:
committed by
Nicolas B. Pierron
parent
e3eff53037
commit
0a0a29fd0b
+6
-1
@@ -200,7 +200,12 @@ in rec {
|
||||
let
|
||||
coerce = def: if isFunction def then def else { config = def; };
|
||||
modules = opts' ++ map (def: { _file = def.file; imports = [(coerce def.value)]; }) defs;
|
||||
in (evalModules { inherit modules; args.name = last loc; prefix = loc; }).config;
|
||||
in (evalModules {
|
||||
inherit modules;
|
||||
# !!! See comment about args in lib/modules.nix
|
||||
args.name = last loc;
|
||||
prefix = loc;
|
||||
}).config;
|
||||
getSubOptions = prefix: (evalModules
|
||||
{ modules = opts'; inherit prefix;
|
||||
# FIXME: hack to get shit to evaluate.
|
||||
|
||||
Reference in New Issue
Block a user