treewide: restructure modules directory; add comments to modules top-level import

This commit is contained in:
raf 2024-04-20 18:09:39 +03:00
commit 43263040a4
No known key found for this signature in database
GPG key ID: 02D1DD3FA08B6B29
14 changed files with 218 additions and 181 deletions

View file

@ -0,0 +1,31 @@
{lib, ...}: let
inherit (lib.options) mkOption literalExpression;
inherit (lib.types) listOf str unspecified;
in {
options = {
assertions = mkOption {
type = listOf unspecified;
internal = true;
default = [];
example = literalExpression ''
[
{
assertion = false;
message = "you can't enable this for that reason";
}
]
'';
};
warnings = mkOption {
internal = true;
default = [];
type = listOf str;
example = ["The `foo' service is deprecated and will go away soon!"];
description = ''
This option allows modules to show warnings to users during
the evaluation of the system configuration.
'';
};
};
}