refactor(nixos): simplify registry option definitions #129

Merged
alexion merged 2 commits from refactor/inline-shell-shortcut-type into main 2026-10-05 00:20:30 -04:00
4 changed files with 16 additions and 16 deletions
Showing only changes of commit 8c91a210b2 - Show all commits

View File

@@ -5,40 +5,40 @@
tab = lib.mkOption {
type = lib.types.str;
example = "Apps";
description = "Homepage tab that contains this entry.";
description = "Groups the entry in a Homepage tab.";
};
section = lib.mkOption {
type = lib.types.str;
example = "Media";
description = "Homepage section that contains this entry.";
description = "Groups the entry in a Homepage section.";
};
name = lib.mkOption {
type = lib.types.str;
example = "Navidrome";
description = "Homepage display name for this entry.";
description = "Sets the display name in Homepage.";
};
description = lib.mkOption {
type = lib.types.nullOr lib.types.str;
default = null;
example = "Music";
description = "Homepage description for this entry.";
description = "Sets the description in Homepage.";
};
icon = lib.mkOption {
type = lib.types.nullOr lib.types.str;
default = null;
example = "navidrome.png";
description = "Homepage icon for this entry.";
description = "Sets the icon in Homepage.";
};
href = lib.mkOption {
type = lib.types.nullOr lib.types.str;
default = null;
example = "https://music.alexion.dev";
description = "Homepage link override for this entry.";
description = "Overrides the generated Homepage link.";
};
};
};

View File

@@ -36,7 +36,7 @@
domain = lib.mkOption {
type = lib.types.str;
example = "files.alexion.dev";
description = "Public domain for this route.";
description = "Records the public domain for this route.";
};
protocol = lib.mkOption {
@@ -45,14 +45,14 @@
"https"
"udp"
];
description = "Public protocol for this route.";
description = "Selects the public protocol for this route.";
};
port = lib.mkOption {
type = lib.types.nullOr lib.types.port;
default = null;
example = 3923;
description = "HTTP backend port for an HTTP or HTTPS route.";
description = "Sets the HTTP backend port for an HTTP or HTTPS route.";
};
ports = lib.mkOption {
@@ -62,7 +62,7 @@
2456
2457
];
description = "UDP ports for a UDP route.";
description = "Sets the UDP ports for a UDP route.";
};
};
};

View File

@@ -6,13 +6,13 @@
command = lib.mkOption {
type = lib.types.str;
example = "nvim";
description = "Command expanded by this shell shortcut.";
description = "Sets the command expanded by this shortcut.";
};
abbreviation = lib.mkOption {
type = lib.types.bool;
default = true;
description = "Whether fish realizes this shell shortcut as an abbreviation instead of an alias.";
description = "Uses a Fish abbreviation instead of an alias.";
};
};
}

View File

@@ -5,14 +5,14 @@ let
assertion = lib.mkOption {
type = lib.types.functionTo lib.types.bool;
description = ''
Tests this registry's flattened collected entries.
Tests the registry's flattened entries.
'';
};
message = lib.mkOption {
type = lib.types.str;
description = ''
Describes the registry validation failure.
Describes the validation failure.
'';
};
};
@@ -23,7 +23,7 @@ in
type = lib.mkOption {
type = lib.types.raw;
description = ''
Defines the NixOS option type for one registry entry.
Defines the NixOS option type for a registry entry.
'';
};
@@ -31,7 +31,7 @@ in
type = lib.types.listOf checkType;
default = [ ];
description = ''
Contains validation checks for this registry's flattened collected entries.
Lists validation checks for the registry's flattened entries.
'';
};
};