update some option descriptions

This commit is contained in:
greyweather committed 2026-09-03 13:56:37 +01:00
1 parent 6d8673ea1e
commit a5d0f522da
8 files changed
+21 -16

No files matched your search

+2 -1
View File
@@ -120,7 +120,7 @@ in {
in { in {
enable = lib.mkOption { enable = lib.mkOption {
type = lib.types.bool; type = lib.types.bool;
description = "This option enables documentation for the flake, which is generated with Material for mkDocs and hosted by nginx at localhost:${defaultPort} by default."; description = "Whether to enable documentation for the flake, generated with [Material for mkDocs](https://squidfunk.github.io/mkdocs-material/) and hosted by (containerised) nginx at localhost:${defaultPort} by default.";
default = true; default = true;
}; };
@@ -128,6 +128,7 @@ in {
type = lib.types.str; type = lib.types.str;
description = "This option sets the port used by the nginx server hosting the local documentation site."; description = "This option sets the port used by the nginx server hosting the local documentation site.";
default = defaultPort; default = defaultPort;
readOnly = true;
}; };
}; };
})) ]; })) ];
+2 -2
View File
@@ -12,13 +12,13 @@ in {
enable = lib.mkEnableOption "automatic cleaning of the system with `nh clean`"; enable = lib.mkEnableOption "automatic cleaning of the system with `nh clean`";
dates = lib.mkOption { dates = lib.mkOption {
type = lib.types.str; type = lib.types.str;
description = "This option defines when the cleaning job should run, in the format of [`systemd.time` calendar events](https://www.man7.org/linux/man-pages/man7/systemd.time.7.html#CALENDAR_EVENTS)."; description = "Defines when the cleaning job should run, in the format of [`systemd.time` calendar events](https://www.man7.org/linux/man-pages/man7/systemd.time.7.html#CALENDAR_EVENTS).";
default = "daily"; default = "daily";
example = "Sun 05:00"; example = "Sun 05:00";
}; };
extraArgs = lib.mkOption { extraArgs = lib.mkOption {
type = lib.types.str; type = lib.types.str;
description = "This option sets any extra arguments that should be passed to the `nh clean` command when it is called by this automated service."; description = "Any extra arguments that should be passed to the `nh clean` command when it is called by this service.";
default = "--keep 10 --keep-since 7d"; default = "--keep 10 --keep-since 7d";
}; };
}; };
@@ -6,7 +6,7 @@
}; };
in { in {
imports = [ (inputs.helpers.mkMirroredModulesFlakeModule "graphicsOptions" ({ lib, ... }: { imports = [ (inputs.helpers.mkMirroredModulesFlakeModule "graphicsOptions" ({ lib, ... }: {
options.features.applications.gui.equibop.enable = lib.mkEnableOption "Equibop"; options.features.applications.gui.equibop.enable = lib.mkEnableOption "Equibop, a custom Discord client from the creators of Equicord";
})) ]; })) ];
flake.nixosModules.graphicsOption = { lib, ... }: { flake.nixosModules.graphicsOption = { lib, ... }: {
+1 -1
View File
@@ -2,7 +2,7 @@
imports = [ (inputs.helpers.mkMirroredModulesFlakeModule "globalOptions" ({ lib, ... }: { imports = [ (inputs.helpers.mkMirroredModulesFlakeModule "globalOptions" ({ lib, ... }: {
options.features.shells.defaultShell = lib.mkOption { options.features.shells.defaultShell = lib.mkOption {
type = inputs.helpers.mkEnumFromDirContents "${self}/modules/features/shells"; type = inputs.helpers.mkEnumFromDirContents "${self}/modules/features/shells";
description = "This option controls the shell that should be used as the default, enabling that shell in the process."; description = "The shell that should be used as the default for all users.";
default = "zsh"; default = "zsh";
}; };
})) ]; })) ];
+1 -1
View File
@@ -87,7 +87,7 @@
home-manager.users.${config.info.userName} = lib.mkIf (config.features.nixos.home-manager.enable) { home-manager.users.${config.info.userName} = lib.mkIf (config.features.nixos.home-manager.enable) {
info = { info = {
inherit (config.info) rootPath userName hostName stateVersion; inherit (config.info) rootPath userName hostName stateVersion;
hostPlatform = config.nixpkgs.hostPlatform.system; # hostPlatform = config.nixpkgs.hostPlatform.system;
isStandalone = false; isStandalone = false;
}; };
}; };
+1 -1
View File
@@ -165,4 +165,4 @@
}; };
}; };
}; };
} }
+10 -6
View File
@@ -1,12 +1,12 @@
{ inputs, self, ... }: let { inputs, self, ... }: let
mkExtraPackagesDescription = optionName: "This option is equivalent to `${optionName}`, and exists purely for convenience."; mkExtraPackagesDescription = optionName: "This option is equivalent to `${optionName}`, and exists purely for convenience.";
in { in {
imports = [ (inputs.helpers.mkMirroredModulesFlakeModule "globalOptions" ({ lib, ... }: { imports = [ (inputs.helpers.mkMirroredModulesFlakeModule "globalOptions" ({ lib, config, ... }: {
options.info = { options.info = {
rootPath = lib.mkOption { rootPath = lib.mkOption {
type = lib.types.str; type = lib.types.str;
description = "Used to tell the config the global path to the flake's root directory, in order to perform direct symlinking (not in `/nix/store`)."; description = "Used to tell the config the absolute path to this flake's root directory, in order to perform actual symlinking (not in `/nix/store` but directly in the directory specified here).";
default = "/home/grey/nixos"; defaultText = "/home/<config.info.userName>/flake";
}; };
userName = lib.mkOption { userName = lib.mkOption {
@@ -21,6 +21,10 @@ in {
default = ""; default = "";
}; };
}; };
config = {
info.rootPath = lib.mkDefault "/home/${config.info.userName}/flake";
};
})) ]; })) ];
flake.nixosModules.globalOptions = { lib, ... }: { flake.nixosModules.globalOptions = { lib, ... }: {
@@ -36,19 +40,19 @@ in {
bootLoader = { bootLoader = {
selection = lib.mkOption { selection = lib.mkOption {
type = inputs.helpers.mkEnumFromDirContents "${self}/modules/components/boot-loaders"; type = inputs.helpers.mkEnumFromDirContents "${self}/modules/components/boot-loaders";
description = "This option defines the bootloader that should be used, enabling any config associated with it in the process."; description = "Defines the bootloader that should be used, enabling any config associated with it in the process.";
default = "grub"; default = "grub";
}; };
timeout = lib.mkOption { timeout = lib.mkOption {
type = lib.types.int; type = lib.types.int;
description = "This option defines the timeout length that the bootloader should use, which controls the wait time for keyboard input before selecting the default entry."; description = "Defines the timeout length that the bootloader should use (the wait time for keyboard input before selecting the default entry).";
default = 5; default = 5;
}; };
maxGenerations = lib.mkOption { maxGenerations = lib.mkOption {
type = lib.types.int; type = lib.types.int;
description = "This option defines how many entries should be displayed in the bootloader, which can be useful when there are many NixOS generations present before garbage-collection."; description = "Limits how many entries should be displayed in the bootloader, which can be useful when there are many NixOS generations present before garbage-collection.";
default = 10; default = 10;
}; };
}; };
+3 -3
View File
@@ -4,13 +4,13 @@
components = { components = {
windowManagers = lib.mkOption { windowManagers = lib.mkOption {
type = inputs.helpers.mkOptionalListOfType (inputs.helpers.mkEnumFromDirContents "${self}/modules/components/window-managers"); type = inputs.helpers.mkOptionalListOfType (inputs.helpers.mkEnumFromDirContents "${self}/modules/components/window-managers");
description = "This option defines the window manager(s) that should be installed, enabling any config associated with it in the process. It can be either a list or just one value."; description = "Defines the window manager(s) that should be installed, enabling any config associated with them in the process. It can be either a list or just one value.";
default = []; default = [];
}; };
shells = lib.mkOption { shells = lib.mkOption {
type = inputs.helpers.mkOptionalListOfType (inputs.helpers.mkEnumFromDirContents "${self}/modules/components/shells"); type = inputs.helpers.mkOptionalListOfType (inputs.helpers.mkEnumFromDirContents "${self}/modules/components/shells");
description = "This option defines the graphical shell(s) that should be installed (e.g. Noctalia, DMS), enabling any config associated with it in the process. It can be either a list or just one value."; description = "Defines the graphical shell(s) that should be installed (e.g. Noctalia, DMS), enabling any config associated with them in the process. It can be either a list or just one value.";
default = []; default = [];
}; };
}; };
@@ -20,7 +20,7 @@
flake.nixosModules.graphicsOptions = { lib, ... }: { flake.nixosModules.graphicsOptions = { lib, ... }: {
options.components.displayManager = lib.mkOption { options.components.displayManager = lib.mkOption {
type = inputs.helpers.mkEnumFromDirContents "${self}/modules/components/display-managers"; type = inputs.helpers.mkEnumFromDirContents "${self}/modules/components/display-managers";
description = "This option defines the bootloader that should be used, enabling any config associated with it in the process."; description = "Defines the bootloader that should be used, enabling any config associated with it in the process.";
default = "lightdm"; default = "lightdm";
}; };
}; };