mirror of
https://github.com/nix-community/disko.git
synced 2026-12-01 21:43:29 +01:00
types: refactor topLevel into devices, move output generators to lib
This commit is contained in:
1 parent
271b00593f
commit
5aa3ebcb99
2 files changed
+66
-83
No files matched your search
+7
-7
@@ -4,18 +4,18 @@ let
|
||||
eval = cfg: lib.evalModules {
|
||||
modules = lib.singleton {
|
||||
# _file = toString input;
|
||||
imports = lib.singleton { topLevel.devices = cfg; };
|
||||
imports = lib.singleton { devices = cfg; };
|
||||
options = {
|
||||
topLevel = lib.mkOption {
|
||||
type = types.topLevel;
|
||||
devices = lib.mkOption {
|
||||
type = types.devices;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
in {
|
||||
types = types;
|
||||
create = cfg: (eval cfg).config.topLevel.create;
|
||||
mount = cfg: (eval cfg).config.topLevel.mount;
|
||||
config = cfg: (eval cfg).config.topLevel.config;
|
||||
packages = cfg: (eval cfg).config.topLevel.packages;
|
||||
create = cfg: types.diskoLib.create (eval cfg).config.devices;
|
||||
mount = cfg: types.diskoLib.mount (eval cfg).config.devices;
|
||||
config = cfg: types.diskoLib.config (eval cfg).config.devices;
|
||||
packages = cfg: types.diskoLib.packages (eval cfg).config.devices;
|
||||
}
|
||||
Reference in new issue
Block a user