revert submodule wrapper to align with module functions already doing types #2

Closed
kiara wants to merge 37 commits from kiara/Fediversity:fix-submodule-type into main
3 changed files with 9 additions and 9 deletions
Showing only changes of commit 421d7b6f93 - Show all commits

View file

@ -164,7 +164,8 @@ in
{
inherit (fediversity) example-deployment;
};
expected = {
};
expected =
{
};
};
}

View file

@ -17,7 +17,7 @@ let
;
functionType = import ./function.nix;
application-resources = {
application-resources = submodule {
options.resources = mkOption {
# TODO: maybe transpose, and group the resources by type instead
type = attrsOf (
@ -25,7 +25,7 @@ let
);
};
};
nixops4Deployment = inputs.nixops4.modules.nixops4Deployment.default;
nixops4Deployment = submodule inputs.nixops4.modules.nixops4Deployment.default;
in
{
options = {

View file

@ -5,7 +5,6 @@
let
inherit (lib) mkOption types;
inherit (types)
deferredModule
submodule
functionTo
optionType
@ -14,10 +13,10 @@ in
{
options = {
input-type = mkOption {
type = deferredModule;
type = optionType;
};
output-type = mkOption {
type = deferredModule;
type = optionType;
};
function-type = mkOption {
type = optionType;
@ -26,10 +25,10 @@ in
submodule (function: {
options = {
input = mkOption {
type = submodule config.input-type;
type = config.input-type;
};
output = mkOption {
type = submodule config.output-type;
type = config.output-type;
};
};
})