refactor(natu): remove custom Nix linter

This commit was merged in pull request #184.
This commit is contained in:
2026-10-13 21:59:41 -04:00
parent 08563c6769
commit 55f61f71d8
1104 changed files with 23 additions and 354220 deletions

View File

@@ -4,7 +4,7 @@
...
}:
let
cfg = config.guests.copyparty; # NOLINT(let_order)
cfg = config.guests.copyparty;
in
{
options.guests.copyparty = {

View File

@@ -4,7 +4,7 @@
...
}:
let
cfg = config.guests.homepage; # NOLINT(let_order)
cfg = config.guests.homepage;
environmentFile = "/run/secrets/homepage.env";
in
{

View File

@@ -4,7 +4,7 @@
...
}:
let
cfg = config.guests.palworld; # NOLINT(let_order)
cfg = config.guests.palworld;
steamDir = "/data/steamcmd";
installDir = "/data/server";
stateDir = "/data/state";

View File

@@ -4,7 +4,7 @@
...
}:
let
cfg = config.guests.valheim; # NOLINT(let_order)
cfg = config.guests.valheim;
steamDir = "/data/steamcmd";
installDir = "/data/server";
stateDir = "/data/state";

View File

@@ -8,7 +8,7 @@
}:
# Configures Firefox as the desktop browser.
let
cfg = config.modules.desktop.apps.firefox; # NOLINT(let_order)
cfg = config.modules.desktop.apps.firefox;
in
{
options.modules.desktop.apps.firefox = {

View File

@@ -5,7 +5,7 @@
}:
# Imports existing ZFS pools that hold durable service state.
let
cfg = config.modules.host.zfs; # NOLINT(let_order)
cfg = config.modules.host.zfs;
in
{
options.modules.host.zfs = {

View File

@@ -7,19 +7,17 @@
# Configures inbound and outbound SSH access.
let
cfg = config.modules.network.ssh;
user = config.user.name; # NOLINT(let_order)
user = config.user.name;
# NOLINT(let_order)
workstationNames = [
"neogaia"
"zeus"
];
serverNames = [ "pikachu" ];
isWorkstation = lib.elem config.networking.hostName workstationNames; # NOLINT(let_order)
isServer = lib.elem config.networking.hostName serverNames; # NOLINT(let_order)
isWorkstation = lib.elem config.networking.hostName workstationNames;
isServer = lib.elem config.networking.hostName serverNames;
# NOLINT(let_order)
clientKeyFor = host: builtins.readFile (../../hosts + "/${host}/ssh_user_ed25519_key.pub");
hostKeysFor =
host:
@@ -28,7 +26,6 @@ let
(../../hosts + "/${host}/ssh_host_rsa_key.pub")
];
# NOLINT(let_order)
managedTargets = lib.genAttrs (workstationNames ++ serverNames) (name: {
hostName = registry.address.${name}.self;
clientKey = clientKeyFor name;
@@ -48,7 +45,6 @@ let
};
};
# NOLINT(let_order)
mkTarget = name: target: {
hostName = target.hostName or name;
user = target.user or user;
@@ -57,15 +53,14 @@ let
clientKey = target.clientKey or null;
hostKeys = target.hostKeys or [ ];
};
targets = lib.mapAttrs mkTarget (managedTargets // extraTargets); # NOLINT(let_order)
targets = lib.mapAttrs mkTarget (managedTargets // extraTargets);
clientKeysFor = names: lib.filter (key: key != null) (map (name: targets.${name}.clientKey) names); # NOLINT(let_order)
# NOLINT(let_order)
clientKeysFor = names: lib.filter (key: key != null) (map (name: targets.${name}.clientKey) names);
defaultAuthorizedKeys = lib.flatten (
clientKeysFor workstationNames ++ lib.optional isServer (clientKeysFor serverNames)
);
outboundTargetNames = # NOLINT(let_order)
outboundTargetNames =
let
groupTargets =
if isServer then

View File

@@ -6,7 +6,7 @@
}:
# Configures bridges for tagged VLANs on a physical interface that uses DHCP.
let
cfg = config.modules.network.vlans; # NOLINT(let_order)
cfg = config.modules.network.vlans;
in
{
options.modules.network.vlans = {

View File

@@ -6,7 +6,7 @@
...
}:
let
cfg = config.modules.network.vpn-client; # NOLINT(let_order)
cfg = config.modules.network.vpn-client;
vpnIcon = util.glyph [
"db83"

View File

@@ -6,7 +6,7 @@
...
}:
let
cfg = config.modules.services.copyparty; # NOLINT(let_order)
cfg = config.modules.services.copyparty;
accountName = config.user.name;

View File

@@ -5,7 +5,7 @@
...
}:
let
cfg = config.modules.services.homepage; # NOLINT(let_order)
cfg = config.modules.services.homepage;
derivedAllowedHosts = lib.unique (
lib.optional (selfRoute != null) selfRoute.domain

View File

@@ -4,7 +4,7 @@
...
}:
let
cfg = config.modules.services.navidrome; # NOLINT(let_order)
cfg = config.modules.services.navidrome;
in
{
options.modules.services.navidrome = {

View File

@@ -6,7 +6,7 @@
}:
# fish for the primary user, configured through home-manager.
let
cfg = config.modules.shell.fish; # NOLINT(let_order)
cfg = config.modules.shell.fish;
commandsOf = shortcuts: lib.mapAttrs (_name: shortcut: shortcut.command) shortcuts;
shortcuts = lib.attrByPath [ config.networking.hostName ] { } config.registry.shell-shortcut;
user = config.user.name;