Merge pull request #65728 from Infinisil/types-eithers
lib/types: Add oneOf, extension of either to a list of typeswip/yesman
commit
6f6468bef3
@ -0,0 +1,5 @@ |
||||
{ lib, ... }: { |
||||
options.value = lib.mkOption { |
||||
type = lib.types.either lib.types.int lib.types.str; |
||||
}; |
||||
} |
@ -0,0 +1,9 @@ |
||||
{ lib, ... }: { |
||||
options.value = lib.mkOption { |
||||
type = lib.types.oneOf [ |
||||
lib.types.int |
||||
(lib.types.listOf lib.types.int) |
||||
lib.types.str |
||||
]; |
||||
}; |
||||
} |
Loading…
Reference in new issue