Clean up the Windows configuration
This commit is contained in:
parent
c2b83d666a
commit
9ec3aa95c9
|
@ -7,18 +7,11 @@
|
|||
types
|
||||
;
|
||||
|
||||
setupUser = config.valhalla.setupUser.name;
|
||||
capitalize = (import ../text.nix { inherit lib; }).capitalize;
|
||||
|
||||
winType = types.submodule (
|
||||
{ config, ... }: {
|
||||
options = {
|
||||
setupUser = mkOption {
|
||||
type = types.str;
|
||||
description = "The name of the user for setting up Windows.";
|
||||
default = capitalize setupUser;
|
||||
};
|
||||
|
||||
in {
|
||||
options = {
|
||||
valhalla = {
|
||||
windows = {
|
||||
dualboot = {
|
||||
enable = mkEnableOption "dual boot";
|
||||
|
||||
|
@ -41,19 +34,13 @@
|
|||
dynamicLighting = mkEnableOption "dynamic lighting";
|
||||
adware = mkEnableOption "adware"; # Fuck you for displaying ads on an OS I fricking paid for!
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
config = {
|
||||
dualboot.linuxPercentage = mkIf (!config.dualboot.enable) 0;
|
||||
};
|
||||
});
|
||||
in {
|
||||
options = {
|
||||
valhalla = {
|
||||
windows = mkOption {
|
||||
type = winType;
|
||||
description = "The options for setting up Windows.";
|
||||
default = {};
|
||||
};
|
||||
config = {
|
||||
valhalla.windows = {
|
||||
setupUser.name = capitalize config.valhalla.setupUser.name;
|
||||
dualboot.linuxPercentage = mkIf (!config.valhalla.windows.dualboot.enable) 0;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue