more progress on custom options config

This commit is contained in:
greyweather committed 2026-08-27 19:28:28 +01:00
1 parent f770b83b5c
commit 765f346eb6
26 files changed
+900 -561

No files matched your search

+41
View File
@@ -0,0 +1,41 @@
{ inputs, self, ... }: {
flake.nixosModules.global = { pkgs, config, lib, ... }: {
options = {
info = {
rootPath = lib.mkOption {
type = lib.types.str;
default = "/home/grey/nixos";
};
hostName = lib.mkOption {
type = lib.types.str;
default = "";
};
stateVersion = lib.mkOption {
type = lib.types.str;
default = "";
};
};
components.bootLoader = lib.mkOption {
type = lib.types.enum (map (name: lib.removeSuffix ".nix" name) (
builtins.attrNames (builtins.readDir "${self}/modules/components/boot-loaders")
));
default = "grub";
};
features.applications = {
extraPackages = lib.mkOption {
type = lib.types.listOf (lib.types.package);
default = [];
};
extraUserPackages = lib.mkOption {
type = lib.types.listOf (lib.types.package);
default = [];
};
};
};
};
}