Support module keys that are paths

This commit is contained in:
Eelco Dolstra 2013-10-29 14:15:33 +01:00
parent 985f1f2d8a
commit 9143910139
1 changed files with 2 additions and 2 deletions

View File

@ -42,14 +42,14 @@ rec {
throw "Module `${key}' has an unsupported attribute `${head (attrNames badAttrs)}'." throw "Module `${key}' has an unsupported attribute `${head (attrNames badAttrs)}'."
else else
{ inherit file; { inherit file;
key = m.key or key; key = toString m.key or key;
imports = m.imports or []; imports = m.imports or [];
options = m.options or {}; options = m.options or {};
config = m.config or {}; config = m.config or {};
} }
else else
{ inherit file; { inherit file;
key = m.key or key; key = toString m.key or key;
imports = m.require or [] ++ m.imports or []; imports = m.require or [] ++ m.imports or [];
options = {}; options = {};
config = removeAttrs m ["key" "require" "imports"]; config = removeAttrs m ["key" "require" "imports"];