Better disko setup

This commit is contained in:
Jan-Bulthuis committed 2025-05-29 14:19:19 +02:00
1 parent f0d56df191
commit 51ab89cd98
4 files changed
+77 -16

No files matched your search

+24
View File
@@ -0,0 +1,24 @@
{
lib,
config,
inputs,
...
}:
with lib;
let
cfg = config.modules.disko;
profile = import "${inputs.self}/profiles/disko/${cfg.profile}.nix";
in
{
options.modules.disko = {
enable = mkEnableOption "Disko module";
profile = mkOption {
type = types.str;
default = null;
description = "The profile to use for the disko module.";
};
};
config = mkIf cfg.enable { disko.devices = profile.disko.devices; };
}