From 5da6eafceb2ea15b39de54d853cc224409e4c1a9 Mon Sep 17 00:00:00 2001 From: awwpotato Date: Wed, 7 May 2025 08:03:21 -0700 Subject: [PATCH] treewide: remove unused code (#6985) --- docs/flake.nix | 2 +- home-manager/home-manager.nix | 11 - lib/default.nix | 5 - modules/lib/dag.nix | 1 - modules/lib/types-dag.nix | 11 - modules/lib/types.nix | 1 - modules/programs/distrobox.nix | 2 - modules/programs/fish.nix | 44 +- modules/programs/gnome-terminal.nix | 411 +++++++------ modules/programs/joshuto.nix | 2 +- modules/programs/lapce.nix | 1 - modules/programs/mbsync-accounts.nix | 4 +- modules/programs/mergiraf.nix | 2 - modules/programs/ncmpcpp.nix | 30 +- modules/programs/neovim.nix | 1 - modules/programs/onedrive.nix | 2 - modules/programs/papis.nix | 2 +- modules/programs/pyenv.nix | 2 - modules/programs/qcal.nix | 8 - modules/programs/sftpman.nix | 100 ++-- modules/programs/ssh.nix | 557 +++++++++--------- modules/programs/thunderbird.nix | 2 +- modules/programs/wlogout.nix | 1 - modules/programs/zplug.nix | 29 +- modules/services/lxqt-policykit-agent.nix | 2 - modules/services/polkit-gnome.nix | 2 - modules/systemd.nix | 1 - .../darwin/user-defaults/opts-currenthost.nix | 9 - templates/nix-darwin/flake.nix | 3 +- templates/nixos/flake.nix | 2 +- tests/default.nix | 6 +- tests/flake.nix | 2 +- .../standalone/alice-home-init.nix | 2 - .../standalone/alice-home-next.nix | 2 +- .../standalone/home-with-symbols-init.nix | 2 - .../standalone/home-with-symbols.nix | 2 - tests/integration/standalone/nh.nix | 2 - tests/lib/generators/tokdl.nix | 2 +- tests/lib/generators/toscfg-empty.nix | 2 +- .../generators/toscfg-err-dir-empty-name.nix | 2 +- tests/lib/generators/toscfg-example.nix | 2 +- tests/lib/types/dag-merge.nix | 1 - tests/modules/misc/xdg/default-locations.nix | 2 +- tests/modules/misc/xdg/system-dirs.nix | 1 - tests/modules/misc/xdg/user-dirs-null.nix | 1 - .../cava/cava-basic-configuration.nix | 2 +- .../cavalier/cavalier-cava-settings.nix | 2 +- .../cavalier/cavalier-general-settings.nix | 2 +- tests/modules/programs/darcs/author.nix | 2 - tests/modules/programs/darcs/boring.nix | 2 - tests/modules/programs/fish/manpage.nix | 2 +- .../programs/i3status-rust/with-custom.nix | 1 - .../programs/i3status-rust/with-default.nix | 1 - .../i3status-rust/with-extra-settings.nix | 1 - .../i3status-rust/with-multiple-bars.nix | 1 - .../i3status-rust/with-version-02xx.nix | 1 - .../kakoune/whitespace-highlighter.nix | 2 - .../programs/mangohud/basic-configuration.nix | 2 +- .../programs/mergiraf/basic-configuration.nix | 2 - .../programs/mpv/mpv-example-settings.nix | 2 - .../programs/mpv/mpv-invalid-settings.nix | 2 - tests/modules/programs/ssh/includes.nix | 2 - .../programs/swayr/basic-configuration.nix | 2 +- .../programs/swayr/empty-configuration.nix | 2 +- .../programs/vesktop/basic-configuration.nix | 2 +- tests/modules/programs/zsh/aliases.nix | 2 - .../services/dropbox/basic-configuration.nix | 2 +- .../services/espanso/basic-configuration.nix | 5 +- .../services/fnott/example-settings.nix | 1 - .../services/fnott/systemd-user-service.nix | 1 - .../gromit-mpx/basic-configuration.nix | 2 +- .../gromit-mpx/default-configuration.nix | 2 +- .../services/kanshi/alias-assertion.nix | 2 +- .../services/kanshi/basic-configuration.nix | 2 +- .../services/kanshi/new-configuration.nix | 2 +- .../mpdscribble/basic-configuration.nix | 3 - .../pantalaimon/basic-configuration.nix | 2 +- .../services/parcellite/parcellite.nix | 2 +- .../basic-configuration.nix | 2 +- .../default-configuration.nix | 2 +- .../services/polybar/basic-configuration.nix | 2 +- .../services/polybar/empty-configuration.nix | 2 +- tests/modules/services/sxhkd/service.nix | 2 +- .../services/trayer/basic-configuration.nix | 2 +- .../services/wlsunset/wlsunset-service.nix | 2 +- .../xsettingsd/basic-configuration.nix | 2 +- tests/modules/systemd/empty-user-config.nix | 2 - 87 files changed, 613 insertions(+), 749 deletions(-) diff --git a/docs/flake.nix b/docs/flake.nix index 4e71ce7e..98fb1233 100644 --- a/docs/flake.nix +++ b/docs/flake.nix @@ -11,9 +11,9 @@ outputs = { - self, nixpkgs, scss-reset, + ... }: let supportedSystems = [ diff --git a/home-manager/home-manager.nix b/home-manager/home-manager.nix index 7204a47e..89dd6613 100644 --- a/home-manager/home-manager.nix +++ b/home-manager/home-manager.nix @@ -3,20 +3,9 @@ confPath, confAttr ? null, check ? true, - newsReadIdsFile ? null, }: let - inherit (pkgs.lib) - concatMapStringsSep - fileContents - filter - length - optionalString - removeSuffix - replaceStrings - splitString - ; env = import ../modules { configuration = diff --git a/lib/default.nix b/lib/default.nix index 19eb2675..4b76c64d 100644 --- a/lib/default.nix +++ b/lib/default.nix @@ -10,11 +10,6 @@ check ? true, # Deprecated: configuration ? null, - extraModules ? null, - stateVersion ? null, - username ? null, - homeDirectory ? null, - system ? null, }@args: let msgForRemovedArg = '' diff --git a/modules/lib/dag.nix b/modules/lib/dag.nix index 448df330..c7091956 100644 --- a/modules/lib/dag.nix +++ b/modules/lib/dag.nix @@ -126,7 +126,6 @@ in i: before: after: entries: let name = "${tag}-${toString i}"; - i' = i + 1; in if entries == [ ] then hm.dag.empty diff --git a/modules/lib/types-dag.nix b/modules/lib/types-dag.nix index 3cea2151..9f17dc6a 100644 --- a/modules/lib/types-dag.nix +++ b/modules/lib/types-dag.nix @@ -2,24 +2,13 @@ let inherit (lib) - concatStringsSep defaultFunctor - fixedWidthNumber hm - imap1 - isAttrs - isList - length - listToAttrs - mapAttrs mkIf mkOrder mkOption mkOptionType - nameValuePair - stringLength types - warn ; dagEntryOf = diff --git a/modules/lib/types.nix b/modules/lib/types.nix index 93e9807a..4c88415e 100644 --- a/modules/lib/types.nix +++ b/modules/lib/types.nix @@ -16,7 +16,6 @@ let mergeAttrs mergeDefaultOption mergeOneOption - mergeOptions mkOption mkOptionType showFiles diff --git a/modules/programs/distrobox.nix b/modules/programs/distrobox.nix index 0cf51738..722129f2 100644 --- a/modules/programs/distrobox.nix +++ b/modules/programs/distrobox.nix @@ -6,8 +6,6 @@ }: let inherit (lib) - generators - types mkIf mkEnableOption mkPackageOption diff --git a/modules/programs/fish.nix b/modules/programs/fish.nix index 2846ad1e..8d6142d4 100644 --- a/modules/programs/fish.nix +++ b/modules/programs/fish.nix @@ -16,31 +16,28 @@ let cfg = config.programs.fish; - pluginModule = types.submodule ( - { config, ... }: - { - options = { - src = mkOption { - type = types.path; - description = '' - Path to the plugin folder. + pluginModule = types.submodule { + options = { + src = mkOption { + type = types.path; + description = '' + Path to the plugin folder. - Relevant pieces will be added to the fish function path and - the completion path. The {file}`init.fish` and - {file}`key_binding.fish` files are sourced if - they exist. - ''; - }; - - name = mkOption { - type = types.str; - description = '' - The name of the plugin. - ''; - }; + Relevant pieces will be added to the fish function path and + the completion path. The {file}`init.fish` and + {file}`key_binding.fish` files are sourced if + they exist. + ''; }; - } - ); + + name = mkOption { + type = types.str; + description = '' + The name of the plugin. + ''; + }; + }; + }; functionModule = types.submodule { options = { @@ -480,7 +477,6 @@ in destructiveSymlinkJoin = args_@{ name, - paths, preferLocalBuild ? true, allowSubstitutes ? false, postBuild ? "", diff --git a/modules/programs/gnome-terminal.nix b/modules/programs/gnome-terminal.nix index ceb52266..5ffeb6af 100644 --- a/modules/programs/gnome-terminal.nix +++ b/modules/programs/gnome-terminal.nix @@ -17,221 +17,212 @@ let "tty" ]; - backForeSubModule = types.submodule ( - { ... }: - { - options = { - foreground = mkOption { - type = types.str; - description = "The foreground color."; - }; - - background = mkOption { - type = types.str; - description = "The background color."; - }; + backForeSubModule = types.submodule { + options = { + foreground = mkOption { + type = types.str; + description = "The foreground color."; }; - } - ); - profileColorsSubModule = types.submodule ( - { ... }: - { - options = { - foregroundColor = mkOption { - type = types.str; - description = "The foreground color."; - }; - - backgroundColor = mkOption { - type = types.str; - description = "The background color."; - }; - - boldColor = mkOption { - default = null; - type = types.nullOr types.str; - description = "The bold color, null to use same as foreground."; - }; - - palette = mkOption { - type = types.listOf types.str; - description = "The terminal palette."; - }; - - cursor = mkOption { - default = null; - type = types.nullOr backForeSubModule; - description = "The color for the terminal cursor."; - }; - - highlight = mkOption { - default = null; - type = types.nullOr backForeSubModule; - description = "The colors for the terminal’s highlighted area."; - }; + background = mkOption { + type = types.str; + description = "The background color."; }; - } - ); + }; + }; - profileSubModule = types.submodule ( - { name, config, ... }: - { - options = { - default = mkOption { - default = false; - type = types.bool; - description = "Whether this should be the default profile."; - }; - - visibleName = mkOption { - type = types.str; - description = "The profile name."; - }; - - colors = mkOption { - default = null; - type = types.nullOr profileColorsSubModule; - description = "The terminal colors, null to use system default."; - }; - - cursorBlinkMode = mkOption { - default = "system"; - type = types.enum [ - "system" - "on" - "off" - ]; - description = "The cursor blink mode."; - }; - - cursorShape = mkOption { - default = "block"; - type = types.enum [ - "block" - "ibeam" - "underline" - ]; - description = "The cursor shape."; - }; - - font = mkOption { - default = null; - type = types.nullOr types.str; - description = "The font name, null to use system default."; - }; - - allowBold = mkOption { - default = null; - type = types.nullOr types.bool; - description = '' - If `true`, allow applications in the - terminal to make text boldface. - ''; - }; - - scrollOnOutput = mkOption { - default = true; - type = types.bool; - description = "Whether to scroll when output is written."; - }; - - showScrollbar = mkOption { - default = true; - type = types.bool; - description = "Whether the scroll bar should be visible."; - }; - - scrollbackLines = mkOption { - default = 10000; - type = types.nullOr types.int; - description = '' - The number of scrollback lines to keep, null for infinite. - ''; - }; - - customCommand = mkOption { - default = null; - type = types.nullOr types.str; - description = '' - The command to use to start the shell, or null for default shell. - ''; - }; - - loginShell = mkOption { - default = false; - type = types.bool; - description = "Run command as a login shell."; - }; - - backspaceBinding = mkOption { - default = "ascii-delete"; - type = eraseBinding; - description = '' - Which string the terminal should send to an application when the user - presses the *Backspace* key. - - `auto` - : Attempt to determine the right value from the terminal's IO settings. - - `ascii-backspace` - : Send an ASCII backspace character (`0x08`). - - `ascii-delete` - : Send an ASCII delete character (`0x7F`). - - `delete-sequence` - : Send the `@7` control sequence. - - `tty` - : Send terminal's "erase" setting. - ''; - }; - - boldIsBright = mkOption { - default = null; - type = types.nullOr types.bool; - description = "Whether bold text is shown in bright colors."; - }; - - deleteBinding = mkOption { - default = "delete-sequence"; - type = eraseBinding; - description = '' - Which string the terminal should send to an application when the user - presses the *Delete* key. - - `auto` - : Send the `@7` control sequence. - - `ascii-backspace` - : Send an ASCII backspace character (`0x08`). - - `ascii-delete` - : Send an ASCII delete character (`0x7F`). - - `delete-sequence` - : Send the `@7` control sequence. - - `tty` - : Send terminal's "erase" setting. - ''; - }; - - audibleBell = mkOption { - default = true; - type = types.bool; - description = "Turn on/off the terminal's bell."; - }; - - transparencyPercent = mkOption { - default = null; - type = types.nullOr (types.ints.between 0 100); - description = "Background transparency in percent."; - }; + profileColorsSubModule = types.submodule { + options = { + foregroundColor = mkOption { + type = types.str; + description = "The foreground color."; }; - } - ); + + backgroundColor = mkOption { + type = types.str; + description = "The background color."; + }; + + boldColor = mkOption { + default = null; + type = types.nullOr types.str; + description = "The bold color, null to use same as foreground."; + }; + + palette = mkOption { + type = types.listOf types.str; + description = "The terminal palette."; + }; + + cursor = mkOption { + default = null; + type = types.nullOr backForeSubModule; + description = "The color for the terminal cursor."; + }; + + highlight = mkOption { + default = null; + type = types.nullOr backForeSubModule; + description = "The colors for the terminal’s highlighted area."; + }; + }; + }; + + profileSubModule = types.submodule { + options = { + default = mkOption { + default = false; + type = types.bool; + description = "Whether this should be the default profile."; + }; + + visibleName = mkOption { + type = types.str; + description = "The profile name."; + }; + + colors = mkOption { + default = null; + type = types.nullOr profileColorsSubModule; + description = "The terminal colors, null to use system default."; + }; + + cursorBlinkMode = mkOption { + default = "system"; + type = types.enum [ + "system" + "on" + "off" + ]; + description = "The cursor blink mode."; + }; + + cursorShape = mkOption { + default = "block"; + type = types.enum [ + "block" + "ibeam" + "underline" + ]; + description = "The cursor shape."; + }; + + font = mkOption { + default = null; + type = types.nullOr types.str; + description = "The font name, null to use system default."; + }; + + allowBold = mkOption { + default = null; + type = types.nullOr types.bool; + description = '' + If `true`, allow applications in the + terminal to make text boldface. + ''; + }; + + scrollOnOutput = mkOption { + default = true; + type = types.bool; + description = "Whether to scroll when output is written."; + }; + + showScrollbar = mkOption { + default = true; + type = types.bool; + description = "Whether the scroll bar should be visible."; + }; + + scrollbackLines = mkOption { + default = 10000; + type = types.nullOr types.int; + description = '' + The number of scrollback lines to keep, null for infinite. + ''; + }; + + customCommand = mkOption { + default = null; + type = types.nullOr types.str; + description = '' + The command to use to start the shell, or null for default shell. + ''; + }; + + loginShell = mkOption { + default = false; + type = types.bool; + description = "Run command as a login shell."; + }; + + backspaceBinding = mkOption { + default = "ascii-delete"; + type = eraseBinding; + description = '' + Which string the terminal should send to an application when the user + presses the *Backspace* key. + + `auto` + : Attempt to determine the right value from the terminal's IO settings. + + `ascii-backspace` + : Send an ASCII backspace character (`0x08`). + + `ascii-delete` + : Send an ASCII delete character (`0x7F`). + + `delete-sequence` + : Send the `@7` control sequence. + + `tty` + : Send terminal's "erase" setting. + ''; + }; + + boldIsBright = mkOption { + default = null; + type = types.nullOr types.bool; + description = "Whether bold text is shown in bright colors."; + }; + + deleteBinding = mkOption { + default = "delete-sequence"; + type = eraseBinding; + description = '' + Which string the terminal should send to an application when the user + presses the *Delete* key. + + `auto` + : Send the `@7` control sequence. + + `ascii-backspace` + : Send an ASCII backspace character (`0x08`). + + `ascii-delete` + : Send an ASCII delete character (`0x7F`). + + `delete-sequence` + : Send the `@7` control sequence. + + `tty` + : Send terminal's "erase" setting. + ''; + }; + + audibleBell = mkOption { + default = true; + type = types.bool; + description = "Turn on/off the terminal's bell."; + }; + + transparencyPercent = mkOption { + default = null; + type = types.nullOr (types.ints.between 0 100); + description = "Background transparency in percent."; + }; + }; + }; buildProfileSet = pcfg: diff --git a/modules/programs/joshuto.nix b/modules/programs/joshuto.nix index 28a16458..58c116fe 100644 --- a/modules/programs/joshuto.nix +++ b/modules/programs/joshuto.nix @@ -5,7 +5,7 @@ ... }: let - inherit (lib) mkIf mkOption types; + inherit (lib) mkIf mkOption; cfg = config.programs.joshuto; tomlFormat = pkgs.formats.toml { }; diff --git a/modules/programs/lapce.nix b/modules/programs/lapce.nix index d5de5fbe..78d1ae1f 100644 --- a/modules/programs/lapce.nix +++ b/modules/programs/lapce.nix @@ -173,7 +173,6 @@ let author, name, version, - hash, }@args: pkgs.stdenvNoCC.mkDerivation { pname = "lapce-plugin-${author}-${name}"; diff --git a/modules/programs/mbsync-accounts.nix b/modules/programs/mbsync-accounts.nix index ce41be48..048299f6 100644 --- a/modules/programs/mbsync-accounts.nix +++ b/modules/programs/mbsync-accounts.nix @@ -12,7 +12,7 @@ let ]); perAccountGroups = - { name, config, ... }: + { name, ... }: { options = { name = mkOption { @@ -43,7 +43,7 @@ let # Options for configuring channel(s) that will be composed together into a group. channel = - { name, config, ... }: + { name, ... }: { options = { name = mkOption { diff --git a/modules/programs/mergiraf.nix b/modules/programs/mergiraf.nix index 8a0ab998..80a18ab6 100644 --- a/modules/programs/mergiraf.nix +++ b/modules/programs/mergiraf.nix @@ -8,8 +8,6 @@ let inherit (lib) mkEnableOption mkPackageOption - types - literalExpression mkIf maintainers ; diff --git a/modules/programs/ncmpcpp.nix b/modules/programs/ncmpcpp.nix index b538874a..68dcaa12 100644 --- a/modules/programs/ncmpcpp.nix +++ b/modules/programs/ncmpcpp.nix @@ -43,25 +43,21 @@ let str ]; - bindingType = types.submodule ( - { name, config, ... }: - { - options = { - key = mkOption { - type = types.str; - description = "Key to bind."; - example = "j"; - }; - - command = mkOption { - type = with types; either str (listOf str); - description = "Command or sequence of commands to be executed."; - example = "scroll_down"; - }; + bindingType = types.submodule { + options = { + key = mkOption { + type = types.str; + description = "Key to bind."; + example = "j"; }; - } - ); + command = mkOption { + type = with types; either str (listOf str); + description = "Command or sequence of commands to be executed."; + example = "scroll_down"; + }; + }; + }; in { meta.maintainers = [ lib.hm.maintainers.olmokramer ]; diff --git a/modules/programs/neovim.nix b/modules/programs/neovim.nix index e0173bbd..a7353a19 100644 --- a/modules/programs/neovim.nix +++ b/modules/programs/neovim.nix @@ -447,7 +447,6 @@ in programs.neovim.generatedConfigs = let grouped = lib.lists.groupBy (x: x.type) pluginsNormalized; - concatConfigs = lib.concatMapStrings (p: p.config); configsOnly = lib.foldl (acc: p: if p.config != null then acc ++ [ p.config ] else acc) [ ]; in lib.mapAttrs (name: vals: lib.concatStringsSep "\n" (configsOnly vals)) grouped; diff --git a/modules/programs/onedrive.nix b/modules/programs/onedrive.nix index 80cf956c..e3435ce4 100644 --- a/modules/programs/onedrive.nix +++ b/modules/programs/onedrive.nix @@ -11,8 +11,6 @@ let mkPackageOption mkOption types - concatStringsSep - mapAttrsToList ; cfg = config.programs.onedrive; diff --git a/modules/programs/papis.nix b/modules/programs/papis.nix index ff060080..ec87ddd7 100644 --- a/modules/programs/papis.nix +++ b/modules/programs/papis.nix @@ -55,7 +55,7 @@ in libraries = mkOption { type = types.attrsOf ( types.submodule ( - { config, name, ... }: + { name, ... }: { options = { name = mkOption { diff --git a/modules/programs/pyenv.nix b/modules/programs/pyenv.nix index d3a92853..f6593f90 100644 --- a/modules/programs/pyenv.nix +++ b/modules/programs/pyenv.nix @@ -9,8 +9,6 @@ let cfg = config.programs.pyenv; - tomlFormat = pkgs.formats.toml { }; - in { meta.maintainers = with lib.maintainers; [ tmarkus ]; diff --git a/modules/programs/qcal.nix b/modules/programs/qcal.nix index b1eb8774..60fe7bb8 100644 --- a/modules/programs/qcal.nix +++ b/modules/programs/qcal.nix @@ -13,14 +13,6 @@ let lib.filterAttrs (_: a: a.qcal.enable) config.accounts.calendar.accounts ); - rename = - oldname: - builtins.getAttr oldname { - url = "Url"; - userName = "Username"; - passwordCommand = "PasswordCmd"; - }; - filteredAccounts = let mkAccount = diff --git a/modules/programs/sftpman.nix b/modules/programs/sftpman.nix index 39c9e1c3..0201a6fc 100644 --- a/modules/programs/sftpman.nix +++ b/modules/programs/sftpman.nix @@ -11,66 +11,64 @@ let jsonFormat = pkgs.formats.json { }; - mountOpts = - { config, name, ... }: - { - options = { - host = mkOption { - type = types.str; - description = "The host to connect to."; - }; + mountOpts = { + options = { + host = mkOption { + type = types.str; + description = "The host to connect to."; + }; - port = mkOption { - type = types.port; - default = 22; - description = "The port to connect to."; - }; + port = mkOption { + type = types.port; + default = 22; + description = "The port to connect to."; + }; - user = mkOption { - type = types.str; - description = "The username to authenticate with."; - }; + user = mkOption { + type = types.str; + description = "The username to authenticate with."; + }; - mountOptions = mkOption { - type = types.listOf types.str; - default = [ ]; - description = "Options to pass to sshfs."; - }; + mountOptions = mkOption { + type = types.listOf types.str; + default = [ ]; + description = "Options to pass to sshfs."; + }; - mountPoint = mkOption { - type = types.str; - description = "The remote path to mount."; - }; + mountPoint = mkOption { + type = types.str; + description = "The remote path to mount."; + }; - authType = mkOption { - type = types.enum [ - "password" - "publickey" - "hostbased" - "keyboard-interactive" - "gssapi-with-mic" - ]; - default = "publickey"; - description = "The authentication method to use."; - }; + authType = mkOption { + type = types.enum [ + "password" + "publickey" + "hostbased" + "keyboard-interactive" + "gssapi-with-mic" + ]; + default = "publickey"; + description = "The authentication method to use."; + }; - sshKey = mkOption { - type = types.nullOr types.str; - default = cfg.defaultSshKey; - defaultText = lib.literalExpression "config.programs.sftpman.defaultSshKey"; - description = '' - Path to the SSH key to use for authentication. - Only applies if authMethod is `publickey`. - ''; - }; + sshKey = mkOption { + type = types.nullOr types.str; + default = cfg.defaultSshKey; + defaultText = lib.literalExpression "config.programs.sftpman.defaultSshKey"; + description = '' + Path to the SSH key to use for authentication. + Only applies if authMethod is `publickey`. + ''; + }; - beforeMount = mkOption { - type = types.str; - default = "true"; - description = "Command to run before mounting."; - }; + beforeMount = mkOption { + type = types.str; + default = "true"; + description = "Command to run before mounting."; }; }; + }; in { meta.maintainers = with lib.maintainers; [ fugi ]; diff --git a/modules/programs/ssh.nix b/modules/programs/ssh.nix index b1c1e963..be154c94 100644 --- a/modules/programs/ssh.nix +++ b/modules/programs/ssh.nix @@ -70,288 +70,285 @@ let }; }; - matchBlockModule = types.submodule ( - { dagName, ... }: - { - options = { - host = mkOption { - type = types.nullOr types.str; - default = null; - example = "*.example.org"; - description = '' - `Host` pattern used by this conditional block. - See - {manpage}`ssh_config(5)` - for `Host` block details. - This option is ignored if - {option}`ssh.matchBlocks.*.match` - if defined. - ''; - }; - - match = mkOption { - type = types.nullOr types.str; - default = null; - example = '' - host canonical - host exec "ping -c1 -q 192.168.17.1"''; - description = '' - `Match` block conditions used by this block. See - {manpage}`ssh_config(5)` - for `Match` block details. - This option takes precedence over - {option}`ssh.matchBlocks.*.host` - if defined. - ''; - }; - - port = mkOption { - type = types.nullOr types.port; - default = null; - description = "Specifies port number to connect on remote host."; - }; - - forwardAgent = mkOption { - default = null; - type = types.nullOr types.bool; - description = '' - Whether the connection to the authentication agent (if any) - will be forwarded to the remote machine. - ''; - }; - - forwardX11 = mkOption { - type = types.bool; - default = false; - description = '' - Specifies whether X11 connections will be automatically redirected - over the secure channel and {env}`DISPLAY` set. - ''; - }; - - forwardX11Trusted = mkOption { - type = types.bool; - default = false; - description = '' - Specifies whether remote X11 clients will have full access to the - original X11 display. - ''; - }; - - identitiesOnly = mkOption { - type = types.bool; - default = false; - description = '' - Specifies that ssh should only use the authentication - identity explicitly configured in the - {file}`~/.ssh/config` files or passed on the - ssh command-line, even if {command}`ssh-agent` - offers more identities. - ''; - }; - - identityFile = mkOption { - type = with types; either (listOf str) (nullOr str); - default = [ ]; - apply = - p: - if p == null then - [ ] - else if lib.isString p then - [ p ] - else - p; - description = '' - Specifies files from which the user identity is read. - Identities will be tried in the given order. - ''; - }; - - identityAgent = mkOption { - type = with types; either (listOf str) (nullOr str); - default = [ ]; - apply = - p: - if p == null then - [ ] - else if lib.isString p then - [ p ] - else - p; - description = '' - Specifies the location of the ssh identity agent. - ''; - }; - - user = mkOption { - type = types.nullOr types.str; - default = null; - description = "Specifies the user to log in as."; - }; - - hostname = mkOption { - type = types.nullOr types.str; - default = null; - description = "Specifies the real host name to log into."; - }; - - serverAliveInterval = mkOption { - type = types.int; - default = 0; - description = "Set timeout in seconds after which response will be requested."; - }; - - serverAliveCountMax = mkOption { - type = types.ints.positive; - default = 3; - description = '' - Sets the number of server alive messages which may be sent - without SSH receiving any messages back from the server. - ''; - }; - - sendEnv = mkOption { - type = types.listOf types.str; - default = [ ]; - description = '' - Environment variables to send from the local host to the - server. - ''; - }; - - setEnv = mkOption { - type = - with types; - attrsOf (oneOf [ - str - path - int - float - ]); - default = { }; - description = '' - Environment variables and their value to send to the server. - ''; - }; - - compression = mkOption { - type = types.nullOr types.bool; - default = null; - description = '' - Specifies whether to use compression. Omitted from the host - block when `null`. - ''; - }; - - checkHostIP = mkOption { - type = types.bool; - default = true; - description = '' - Check the host IP address in the - {file}`known_hosts` file. - ''; - }; - - proxyCommand = mkOption { - type = types.nullOr types.str; - default = null; - description = "The command to use to connect to the server."; - }; - - proxyJump = mkOption { - type = types.nullOr types.str; - default = null; - description = "The proxy host to use to connect to the server."; - }; - - certificateFile = mkOption { - type = with types; either (listOf str) (nullOr str); - default = [ ]; - apply = - p: - if p == null then - [ ] - else if lib.isString p then - [ p ] - else - p; - description = '' - Specifies files from which the user certificate is read. - ''; - }; - - addressFamily = mkOption { - default = null; - type = types.nullOr ( - types.enum [ - "any" - "inet" - "inet6" - ] - ); - description = '' - Specifies which address family to use when connecting. - ''; - }; - - localForwards = mkOption { - type = types.listOf forwardModule; - default = [ ]; - example = literalExpression '' - [ - { - bind.port = 8080; - host.address = "10.0.0.13"; - host.port = 80; - } - ]; - ''; - description = '' - Specify local port forwardings. See - {manpage}`ssh_config(5)` for `LocalForward`. - ''; - }; - - remoteForwards = mkOption { - type = types.listOf forwardModule; - default = [ ]; - example = literalExpression '' - [ - { - bind.port = 8080; - host.address = "10.0.0.13"; - host.port = 80; - } - ]; - ''; - description = '' - Specify remote port forwardings. See - {manpage}`ssh_config(5)` for `RemoteForward`. - ''; - }; - - dynamicForwards = mkOption { - type = types.listOf dynamicForwardModule; - default = [ ]; - example = literalExpression '' - [ { port = 8080; } ]; - ''; - description = '' - Specify dynamic port forwardings. See - {manpage}`ssh_config(5)` for `DynamicForward`. - ''; - }; - - extraOptions = mkOption { - type = types.attrsOf types.str; - default = { }; - description = "Extra configuration options for the host."; - }; + matchBlockModule = types.submodule { + options = { + host = mkOption { + type = types.nullOr types.str; + default = null; + example = "*.example.org"; + description = '' + `Host` pattern used by this conditional block. + See + {manpage}`ssh_config(5)` + for `Host` block details. + This option is ignored if + {option}`ssh.matchBlocks.*.match` + if defined. + ''; }; - # config.host = mkDefault dagName; - } - ); + match = mkOption { + type = types.nullOr types.str; + default = null; + example = '' + host canonical + host exec "ping -c1 -q 192.168.17.1"''; + description = '' + `Match` block conditions used by this block. See + {manpage}`ssh_config(5)` + for `Match` block details. + This option takes precedence over + {option}`ssh.matchBlocks.*.host` + if defined. + ''; + }; + + port = mkOption { + type = types.nullOr types.port; + default = null; + description = "Specifies port number to connect on remote host."; + }; + + forwardAgent = mkOption { + default = null; + type = types.nullOr types.bool; + description = '' + Whether the connection to the authentication agent (if any) + will be forwarded to the remote machine. + ''; + }; + + forwardX11 = mkOption { + type = types.bool; + default = false; + description = '' + Specifies whether X11 connections will be automatically redirected + over the secure channel and {env}`DISPLAY` set. + ''; + }; + + forwardX11Trusted = mkOption { + type = types.bool; + default = false; + description = '' + Specifies whether remote X11 clients will have full access to the + original X11 display. + ''; + }; + + identitiesOnly = mkOption { + type = types.bool; + default = false; + description = '' + Specifies that ssh should only use the authentication + identity explicitly configured in the + {file}`~/.ssh/config` files or passed on the + ssh command-line, even if {command}`ssh-agent` + offers more identities. + ''; + }; + + identityFile = mkOption { + type = with types; either (listOf str) (nullOr str); + default = [ ]; + apply = + p: + if p == null then + [ ] + else if lib.isString p then + [ p ] + else + p; + description = '' + Specifies files from which the user identity is read. + Identities will be tried in the given order. + ''; + }; + + identityAgent = mkOption { + type = with types; either (listOf str) (nullOr str); + default = [ ]; + apply = + p: + if p == null then + [ ] + else if lib.isString p then + [ p ] + else + p; + description = '' + Specifies the location of the ssh identity agent. + ''; + }; + + user = mkOption { + type = types.nullOr types.str; + default = null; + description = "Specifies the user to log in as."; + }; + + hostname = mkOption { + type = types.nullOr types.str; + default = null; + description = "Specifies the real host name to log into."; + }; + + serverAliveInterval = mkOption { + type = types.int; + default = 0; + description = "Set timeout in seconds after which response will be requested."; + }; + + serverAliveCountMax = mkOption { + type = types.ints.positive; + default = 3; + description = '' + Sets the number of server alive messages which may be sent + without SSH receiving any messages back from the server. + ''; + }; + + sendEnv = mkOption { + type = types.listOf types.str; + default = [ ]; + description = '' + Environment variables to send from the local host to the + server. + ''; + }; + + setEnv = mkOption { + type = + with types; + attrsOf (oneOf [ + str + path + int + float + ]); + default = { }; + description = '' + Environment variables and their value to send to the server. + ''; + }; + + compression = mkOption { + type = types.nullOr types.bool; + default = null; + description = '' + Specifies whether to use compression. Omitted from the host + block when `null`. + ''; + }; + + checkHostIP = mkOption { + type = types.bool; + default = true; + description = '' + Check the host IP address in the + {file}`known_hosts` file. + ''; + }; + + proxyCommand = mkOption { + type = types.nullOr types.str; + default = null; + description = "The command to use to connect to the server."; + }; + + proxyJump = mkOption { + type = types.nullOr types.str; + default = null; + description = "The proxy host to use to connect to the server."; + }; + + certificateFile = mkOption { + type = with types; either (listOf str) (nullOr str); + default = [ ]; + apply = + p: + if p == null then + [ ] + else if lib.isString p then + [ p ] + else + p; + description = '' + Specifies files from which the user certificate is read. + ''; + }; + + addressFamily = mkOption { + default = null; + type = types.nullOr ( + types.enum [ + "any" + "inet" + "inet6" + ] + ); + description = '' + Specifies which address family to use when connecting. + ''; + }; + + localForwards = mkOption { + type = types.listOf forwardModule; + default = [ ]; + example = literalExpression '' + [ + { + bind.port = 8080; + host.address = "10.0.0.13"; + host.port = 80; + } + ]; + ''; + description = '' + Specify local port forwardings. See + {manpage}`ssh_config(5)` for `LocalForward`. + ''; + }; + + remoteForwards = mkOption { + type = types.listOf forwardModule; + default = [ ]; + example = literalExpression '' + [ + { + bind.port = 8080; + host.address = "10.0.0.13"; + host.port = 80; + } + ]; + ''; + description = '' + Specify remote port forwardings. See + {manpage}`ssh_config(5)` for `RemoteForward`. + ''; + }; + + dynamicForwards = mkOption { + type = types.listOf dynamicForwardModule; + default = [ ]; + example = literalExpression '' + [ { port = 8080; } ]; + ''; + description = '' + Specify dynamic port forwardings. See + {manpage}`ssh_config(5)` for `DynamicForward`. + ''; + }; + + extraOptions = mkOption { + type = types.attrsOf types.str; + default = { }; + description = "Extra configuration options for the host."; + }; + }; + + # config.host = mkDefault dagName; + }; matchBlockStr = key: cf: diff --git a/modules/programs/thunderbird.nix b/modules/programs/thunderbird.nix index f546b2bf..1ed156d9 100644 --- a/modules/programs/thunderbird.nix +++ b/modules/programs/thunderbird.nix @@ -275,7 +275,7 @@ in feedAccounts = mkOption { type = types.attrsOf ( types.submodule ( - { config, name, ... }: + { name, ... }: { options = { name = mkOption { diff --git a/modules/programs/wlogout.nix b/modules/programs/wlogout.nix index f0159b48..b4dba576 100644 --- a/modules/programs/wlogout.nix +++ b/modules/programs/wlogout.nix @@ -7,7 +7,6 @@ let inherit (lib) - all filterAttrs isStorePath literalExpression diff --git a/modules/programs/zplug.nix b/modules/programs/zplug.nix index 053e25a4..ff75378d 100644 --- a/modules/programs/zplug.nix +++ b/modules/programs/zplug.nix @@ -9,25 +9,20 @@ let cfg = config.programs.zsh.zplug; - pluginModule = types.submodule ( - { config, ... }: - { - options = { - name = mkOption { - type = types.str; - description = "The name of the plugin."; - }; - - tags = mkOption { - type = types.listOf types.str; - default = [ ]; - description = "The plugin tags."; - }; + pluginModule = types.submodule { + options = { + name = mkOption { + type = types.str; + description = "The name of the plugin."; }; - } - ); - + tags = mkOption { + type = types.listOf types.str; + default = [ ]; + description = "The plugin tags."; + }; + }; + }; in { options.programs.zsh.zplug = { diff --git a/modules/services/lxqt-policykit-agent.nix b/modules/services/lxqt-policykit-agent.nix index 5839d46c..f66bfe2f 100644 --- a/modules/services/lxqt-policykit-agent.nix +++ b/modules/services/lxqt-policykit-agent.nix @@ -8,8 +8,6 @@ let inherit (lib) mkEnableOption mkPackageOption - types - literalExpression mkIf maintainers ; diff --git a/modules/services/polkit-gnome.nix b/modules/services/polkit-gnome.nix index e8c395a1..32842488 100644 --- a/modules/services/polkit-gnome.nix +++ b/modules/services/polkit-gnome.nix @@ -8,8 +8,6 @@ let inherit (lib) mkEnableOption mkPackageOption - types - literalExpression mkIf maintainers ; diff --git a/modules/systemd.nix b/modules/systemd.nix index a47eab59..091281a7 100644 --- a/modules/systemd.nix +++ b/modules/systemd.nix @@ -12,7 +12,6 @@ let inherit (lib) any attrValues - getAttr hm isBool literalExpression diff --git a/modules/targets/darwin/user-defaults/opts-currenthost.nix b/modules/targets/darwin/user-defaults/opts-currenthost.nix index 94c61a33..a6023547 100644 --- a/modules/targets/darwin/user-defaults/opts-currenthost.nix +++ b/modules/targets/darwin/user-defaults/opts-currenthost.nix @@ -10,15 +10,6 @@ let default = null; } ); - - mkNullableEnableOption = - name: - lib.mkOption { - type = with lib.types; nullOr bool; - default = null; - example = true; - description = "Whether to enable ${name}."; - }; in { freeformType = with lib.types; attrsOf (attrsOf anything); diff --git a/templates/nix-darwin/flake.nix b/templates/nix-darwin/flake.nix index f223f6d3..672cff25 100644 --- a/templates/nix-darwin/flake.nix +++ b/templates/nix-darwin/flake.nix @@ -10,8 +10,7 @@ }; outputs = - inputs@{ - nixpkgs, + { home-manager, darwin, ... diff --git a/templates/nixos/flake.nix b/templates/nixos/flake.nix index 341b6672..1d9966d4 100644 --- a/templates/nixos/flake.nix +++ b/templates/nixos/flake.nix @@ -8,7 +8,7 @@ }; outputs = - inputs@{ nixpkgs, home-manager, ... }: + { nixpkgs, home-manager, ... }: { nixosConfigurations = { hostname = nixpkgs.lib.nixosSystem { diff --git a/tests/default.nix b/tests/default.nix index fc90f236..f42fc404 100644 --- a/tests/default.nix +++ b/tests/default.nix @@ -41,11 +41,7 @@ let if lib.isDerivation value then scrubbedValue // newDrvAttrs else scrubbedValue else value; - scrubDerivations = - attrs: - let - in - lib.mapAttrs scrubDerivation attrs; + scrubDerivations = attrs: lib.mapAttrs scrubDerivation attrs; # Globally unscrub a few selected packages that are used by a wide selection of tests. whitelist = diff --git a/tests/flake.nix b/tests/flake.nix index 8ea0f833..e25319a7 100644 --- a/tests/flake.nix +++ b/tests/flake.nix @@ -18,7 +18,7 @@ inputs.nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable"; outputs = - { self, nixpkgs, ... }: + { nixpkgs, ... }: let forAllSystems = nixpkgs.lib.genAttrs nixpkgs.lib.systems.flakeExposed; in diff --git a/tests/integration/standalone/alice-home-init.nix b/tests/integration/standalone/alice-home-init.nix index e09fad68..491adeec 100644 --- a/tests/integration/standalone/alice-home-init.nix +++ b/tests/integration/standalone/alice-home-init.nix @@ -1,5 +1,3 @@ -{ config, pkgs, ... }: - { # Home Manager needs a bit of information about you and the paths it should # manage. diff --git a/tests/integration/standalone/alice-home-next.nix b/tests/integration/standalone/alice-home-next.nix index 416640ee..0e9fde2b 100644 --- a/tests/integration/standalone/alice-home-next.nix +++ b/tests/integration/standalone/alice-home-next.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ pkgs, ... }: { home.username = "alice"; diff --git a/tests/integration/standalone/home-with-symbols-init.nix b/tests/integration/standalone/home-with-symbols-init.nix index 546bbc33..c35a7aec 100644 --- a/tests/integration/standalone/home-with-symbols-init.nix +++ b/tests/integration/standalone/home-with-symbols-init.nix @@ -1,5 +1,3 @@ -{ config, pkgs, ... }: - { # Home Manager needs a bit of information about you and the paths it should # manage. diff --git a/tests/integration/standalone/home-with-symbols.nix b/tests/integration/standalone/home-with-symbols.nix index ef60b58a..9a8ba148 100644 --- a/tests/integration/standalone/home-with-symbols.nix +++ b/tests/integration/standalone/home-with-symbols.nix @@ -2,8 +2,6 @@ let - inherit (pkgs.lib) escapeShellArg; - nixHome = "/home/alice@home\\extra"; pyHome = "/home/alice@home\\\\extra"; diff --git a/tests/integration/standalone/nh.nix b/tests/integration/standalone/nh.nix index e280f1e6..85057d69 100644 --- a/tests/integration/standalone/nh.nix +++ b/tests/integration/standalone/nh.nix @@ -2,8 +2,6 @@ let - inherit (pkgs.lib) escapeShellArg; - home = "/home/alice"; in diff --git a/tests/lib/generators/tokdl.nix b/tests/lib/generators/tokdl.nix index 92133132..abe4a986 100644 --- a/tests/lib/generators/tokdl.nix +++ b/tests/lib/generators/tokdl.nix @@ -1,4 +1,4 @@ -{ config, lib, ... }: +{ lib, ... }: { home.file."tokdl-result.txt".text = lib.hm.generators.toKDL { } { diff --git a/tests/lib/generators/toscfg-empty.nix b/tests/lib/generators/toscfg-empty.nix index e6800481..4d52ce3e 100644 --- a/tests/lib/generators/toscfg-empty.nix +++ b/tests/lib/generators/toscfg-empty.nix @@ -1,4 +1,4 @@ -{ config, lib, ... }: +{ lib, ... }: { home.file."toscfg-empty-result.txt".text = lib.hm.generators.toSCFG { } { }; diff --git a/tests/lib/generators/toscfg-err-dir-empty-name.nix b/tests/lib/generators/toscfg-err-dir-empty-name.nix index 40f4e1ba..0b140438 100644 --- a/tests/lib/generators/toscfg-err-dir-empty-name.nix +++ b/tests/lib/generators/toscfg-err-dir-empty-name.nix @@ -1,4 +1,4 @@ -{ config, lib, ... }: +{ lib, ... }: { home.file."toscfg-err-dir-empty-name-result.txt".text = lib.hm.generators.toSCFG { } { "" = [ ]; }; diff --git a/tests/lib/generators/toscfg-example.nix b/tests/lib/generators/toscfg-example.nix index 76612b23..ada60214 100644 --- a/tests/lib/generators/toscfg-example.nix +++ b/tests/lib/generators/toscfg-example.nix @@ -1,4 +1,4 @@ -{ config, lib, ... }: +{ lib, ... }: { home.file."toscfg-example-result.txt".text = lib.hm.generators.toSCFG { } { diff --git a/tests/lib/types/dag-merge.nix b/tests/lib/types/dag-merge.nix index 332ddb6b..e0a90627 100644 --- a/tests/lib/types/dag-merge.nix +++ b/tests/lib/types/dag-merge.nix @@ -1,7 +1,6 @@ { config, lib, - pkgs, ... }: diff --git a/tests/modules/misc/xdg/default-locations.nix b/tests/modules/misc/xdg/default-locations.nix index e1e275e5..3af7d145 100644 --- a/tests/modules/misc/xdg/default-locations.nix +++ b/tests/modules/misc/xdg/default-locations.nix @@ -1,4 +1,4 @@ -{ config, lib, ... }: +{ config, ... }: { config = { # Test fallback behavior for stateVersion >= 20.09, which is pure. diff --git a/tests/modules/misc/xdg/system-dirs.nix b/tests/modules/misc/xdg/system-dirs.nix index e8d477f9..240e5ef9 100644 --- a/tests/modules/misc/xdg/system-dirs.nix +++ b/tests/modules/misc/xdg/system-dirs.nix @@ -1,6 +1,5 @@ { config, - lib, pkgs, ... }: diff --git a/tests/modules/misc/xdg/user-dirs-null.nix b/tests/modules/misc/xdg/user-dirs-null.nix index 774ae7f2..9fd878d5 100644 --- a/tests/modules/misc/xdg/user-dirs-null.nix +++ b/tests/modules/misc/xdg/user-dirs-null.nix @@ -1,6 +1,5 @@ { config, - lib, pkgs, ... }: diff --git a/tests/modules/programs/cava/cava-basic-configuration.nix b/tests/modules/programs/cava/cava-basic-configuration.nix index 98936d83..78356c25 100644 --- a/tests/modules/programs/cava/cava-basic-configuration.nix +++ b/tests/modules/programs/cava/cava-basic-configuration.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { programs.cava = { diff --git a/tests/modules/programs/cavalier/cavalier-cava-settings.nix b/tests/modules/programs/cavalier/cavalier-cava-settings.nix index bd3649a1..b4263c04 100644 --- a/tests/modules/programs/cavalier/cavalier-cava-settings.nix +++ b/tests/modules/programs/cavalier/cavalier-cava-settings.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { programs.cavalier = { diff --git a/tests/modules/programs/cavalier/cavalier-general-settings.nix b/tests/modules/programs/cavalier/cavalier-general-settings.nix index 40cc7b3c..48e29ab2 100644 --- a/tests/modules/programs/cavalier/cavalier-general-settings.nix +++ b/tests/modules/programs/cavalier/cavalier-general-settings.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { programs.cavalier = { diff --git a/tests/modules/programs/darcs/author.nix b/tests/modules/programs/darcs/author.nix index 26cfb469..3505bda5 100644 --- a/tests/modules/programs/darcs/author.nix +++ b/tests/modules/programs/darcs/author.nix @@ -1,5 +1,3 @@ -{ pkgs, ... }: - { config = { programs.darcs = { diff --git a/tests/modules/programs/darcs/boring.nix b/tests/modules/programs/darcs/boring.nix index a65205c2..db5e2c62 100644 --- a/tests/modules/programs/darcs/boring.nix +++ b/tests/modules/programs/darcs/boring.nix @@ -1,5 +1,3 @@ -{ pkgs, ... }: - { config = { programs.darcs = { diff --git a/tests/modules/programs/fish/manpage.nix b/tests/modules/programs/fish/manpage.nix index 22df701c..50916cef 100644 --- a/tests/modules/programs/fish/manpage.nix +++ b/tests/modules/programs/fish/manpage.nix @@ -1,4 +1,4 @@ -{ lib, pkgs, ... }: +{ pkgs, ... }: { config = { programs.fish = { diff --git a/tests/modules/programs/i3status-rust/with-custom.nix b/tests/modules/programs/i3status-rust/with-custom.nix index 12bc5cc3..4c80014b 100644 --- a/tests/modules/programs/i3status-rust/with-custom.nix +++ b/tests/modules/programs/i3status-rust/with-custom.nix @@ -1,6 +1,5 @@ { config, - lib, pkgs, ... }: diff --git a/tests/modules/programs/i3status-rust/with-default.nix b/tests/modules/programs/i3status-rust/with-default.nix index 19a698c7..ba9f26c8 100644 --- a/tests/modules/programs/i3status-rust/with-default.nix +++ b/tests/modules/programs/i3status-rust/with-default.nix @@ -1,6 +1,5 @@ { config, - lib, pkgs, ... }: diff --git a/tests/modules/programs/i3status-rust/with-extra-settings.nix b/tests/modules/programs/i3status-rust/with-extra-settings.nix index ee24fc30..a837604c 100644 --- a/tests/modules/programs/i3status-rust/with-extra-settings.nix +++ b/tests/modules/programs/i3status-rust/with-extra-settings.nix @@ -1,6 +1,5 @@ { config, - lib, pkgs, ... }: diff --git a/tests/modules/programs/i3status-rust/with-multiple-bars.nix b/tests/modules/programs/i3status-rust/with-multiple-bars.nix index 3c6f77c3..9198c1bd 100644 --- a/tests/modules/programs/i3status-rust/with-multiple-bars.nix +++ b/tests/modules/programs/i3status-rust/with-multiple-bars.nix @@ -1,6 +1,5 @@ { config, - lib, pkgs, ... }: diff --git a/tests/modules/programs/i3status-rust/with-version-02xx.nix b/tests/modules/programs/i3status-rust/with-version-02xx.nix index 56d17314..8ca1cb55 100644 --- a/tests/modules/programs/i3status-rust/with-version-02xx.nix +++ b/tests/modules/programs/i3status-rust/with-version-02xx.nix @@ -1,6 +1,5 @@ { config, - lib, pkgs, ... }: diff --git a/tests/modules/programs/kakoune/whitespace-highlighter.nix b/tests/modules/programs/kakoune/whitespace-highlighter.nix index 7923906b..dc6506a1 100644 --- a/tests/modules/programs/kakoune/whitespace-highlighter.nix +++ b/tests/modules/programs/kakoune/whitespace-highlighter.nix @@ -1,5 +1,3 @@ -{ lib, ... }: - { imports = [ ./stubs.nix ]; diff --git a/tests/modules/programs/mangohud/basic-configuration.nix b/tests/modules/programs/mangohud/basic-configuration.nix index 98101096..32f47af8 100644 --- a/tests/modules/programs/mangohud/basic-configuration.nix +++ b/tests/modules/programs/mangohud/basic-configuration.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { config = { diff --git a/tests/modules/programs/mergiraf/basic-configuration.nix b/tests/modules/programs/mergiraf/basic-configuration.nix index 78e6e662..c8833284 100644 --- a/tests/modules/programs/mergiraf/basic-configuration.nix +++ b/tests/modules/programs/mergiraf/basic-configuration.nix @@ -1,5 +1,3 @@ -{ config, lib, ... }: - { programs.git.enable = true; programs.mergiraf.enable = true; diff --git a/tests/modules/programs/mpv/mpv-example-settings.nix b/tests/modules/programs/mpv/mpv-example-settings.nix index 50760676..269788d6 100644 --- a/tests/modules/programs/mpv/mpv-example-settings.nix +++ b/tests/modules/programs/mpv/mpv-example-settings.nix @@ -1,7 +1,5 @@ { config, - lib, - pkgs, ... }: diff --git a/tests/modules/programs/mpv/mpv-invalid-settings.nix b/tests/modules/programs/mpv/mpv-invalid-settings.nix index 3600c97c..eece01bf 100644 --- a/tests/modules/programs/mpv/mpv-invalid-settings.nix +++ b/tests/modules/programs/mpv/mpv-invalid-settings.nix @@ -1,6 +1,4 @@ { - config, - lib, pkgs, ... }: diff --git a/tests/modules/programs/ssh/includes.nix b/tests/modules/programs/ssh/includes.nix index 00b80fb4..8930a094 100644 --- a/tests/modules/programs/ssh/includes.nix +++ b/tests/modules/programs/ssh/includes.nix @@ -1,7 +1,5 @@ { config, - lib, - pkgs, ... }: diff --git a/tests/modules/programs/swayr/basic-configuration.nix b/tests/modules/programs/swayr/basic-configuration.nix index ab23fc3c..deb8010f 100644 --- a/tests/modules/programs/swayr/basic-configuration.nix +++ b/tests/modules/programs/swayr/basic-configuration.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { config = { diff --git a/tests/modules/programs/swayr/empty-configuration.nix b/tests/modules/programs/swayr/empty-configuration.nix index f1b4d629..a68c1073 100644 --- a/tests/modules/programs/swayr/empty-configuration.nix +++ b/tests/modules/programs/swayr/empty-configuration.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { config = { diff --git a/tests/modules/programs/vesktop/basic-configuration.nix b/tests/modules/programs/vesktop/basic-configuration.nix index 5748eab1..3a01cac4 100644 --- a/tests/modules/programs/vesktop/basic-configuration.nix +++ b/tests/modules/programs/vesktop/basic-configuration.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { config = { diff --git a/tests/modules/programs/zsh/aliases.nix b/tests/modules/programs/zsh/aliases.nix index 69a33730..abe44dcf 100644 --- a/tests/modules/programs/zsh/aliases.nix +++ b/tests/modules/programs/zsh/aliases.nix @@ -1,5 +1,3 @@ -{ config, ... }: - { programs.zsh = { enable = true; diff --git a/tests/modules/services/dropbox/basic-configuration.nix b/tests/modules/services/dropbox/basic-configuration.nix index 8e3096ea..e5ad0672 100644 --- a/tests/modules/services/dropbox/basic-configuration.nix +++ b/tests/modules/services/dropbox/basic-configuration.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { config = { diff --git a/tests/modules/services/espanso/basic-configuration.nix b/tests/modules/services/espanso/basic-configuration.nix index e5bd516b..9cf03099 100644 --- a/tests/modules/services/espanso/basic-configuration.nix +++ b/tests/modules/services/espanso/basic-configuration.nix @@ -1,7 +1,4 @@ -espansoExtraArgs: -{ config, ... }: - -{ +espansoExtraArgs: { services.espanso = { enable = true; configs = { diff --git a/tests/modules/services/fnott/example-settings.nix b/tests/modules/services/fnott/example-settings.nix index 6b7d4aa1..dca76ae0 100644 --- a/tests/modules/services/fnott/example-settings.nix +++ b/tests/modules/services/fnott/example-settings.nix @@ -1,7 +1,6 @@ { config, lib, - pkgs, ... }: diff --git a/tests/modules/services/fnott/systemd-user-service.nix b/tests/modules/services/fnott/systemd-user-service.nix index 4d955ee2..a2117d82 100644 --- a/tests/modules/services/fnott/systemd-user-service.nix +++ b/tests/modules/services/fnott/systemd-user-service.nix @@ -1,7 +1,6 @@ { config, lib, - pkgs, ... }: diff --git a/tests/modules/services/gromit-mpx/basic-configuration.nix b/tests/modules/services/gromit-mpx/basic-configuration.nix index 380bcb5c..a73cc38f 100644 --- a/tests/modules/services/gromit-mpx/basic-configuration.nix +++ b/tests/modules/services/gromit-mpx/basic-configuration.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { services.gromit-mpx = { diff --git a/tests/modules/services/gromit-mpx/default-configuration.nix b/tests/modules/services/gromit-mpx/default-configuration.nix index b2ca5056..3f15e2bd 100644 --- a/tests/modules/services/gromit-mpx/default-configuration.nix +++ b/tests/modules/services/gromit-mpx/default-configuration.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { services.gromit-mpx = { diff --git a/tests/modules/services/kanshi/alias-assertion.nix b/tests/modules/services/kanshi/alias-assertion.nix index b549a33d..20f4b7ce 100644 --- a/tests/modules/services/kanshi/alias-assertion.nix +++ b/tests/modules/services/kanshi/alias-assertion.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { config = { services.kanshi = { diff --git a/tests/modules/services/kanshi/basic-configuration.nix b/tests/modules/services/kanshi/basic-configuration.nix index 07fecfc8..30f114b8 100644 --- a/tests/modules/services/kanshi/basic-configuration.nix +++ b/tests/modules/services/kanshi/basic-configuration.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { config = { services.kanshi = { diff --git a/tests/modules/services/kanshi/new-configuration.nix b/tests/modules/services/kanshi/new-configuration.nix index 2888f019..febae98a 100644 --- a/tests/modules/services/kanshi/new-configuration.nix +++ b/tests/modules/services/kanshi/new-configuration.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { config = { services.kanshi = { diff --git a/tests/modules/services/mpdscribble/basic-configuration.nix b/tests/modules/services/mpdscribble/basic-configuration.nix index b7e7c9c5..9e10042f 100644 --- a/tests/modules/services/mpdscribble/basic-configuration.nix +++ b/tests/modules/services/mpdscribble/basic-configuration.nix @@ -1,7 +1,4 @@ { - config, - lib, - pkgs, ... }: diff --git a/tests/modules/services/pantalaimon/basic-configuration.nix b/tests/modules/services/pantalaimon/basic-configuration.nix index ac36c0b8..21f762df 100644 --- a/tests/modules/services/pantalaimon/basic-configuration.nix +++ b/tests/modules/services/pantalaimon/basic-configuration.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { config = { diff --git a/tests/modules/services/parcellite/parcellite.nix b/tests/modules/services/parcellite/parcellite.nix index 25e553bc..bc91c77f 100644 --- a/tests/modules/services/parcellite/parcellite.nix +++ b/tests/modules/services/parcellite/parcellite.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { services.parcellite = { diff --git a/tests/modules/services/pass-secret-service/basic-configuration.nix b/tests/modules/services/pass-secret-service/basic-configuration.nix index f5568df7..bf5d6b26 100644 --- a/tests/modules/services/pass-secret-service/basic-configuration.nix +++ b/tests/modules/services/pass-secret-service/basic-configuration.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { services.pass-secret-service = { diff --git a/tests/modules/services/pass-secret-service/default-configuration.nix b/tests/modules/services/pass-secret-service/default-configuration.nix index d418d823..cf2bbe69 100644 --- a/tests/modules/services/pass-secret-service/default-configuration.nix +++ b/tests/modules/services/pass-secret-service/default-configuration.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { services.pass-secret-service = { diff --git a/tests/modules/services/polybar/basic-configuration.nix b/tests/modules/services/polybar/basic-configuration.nix index b61b3eb4..227c54ab 100644 --- a/tests/modules/services/polybar/basic-configuration.nix +++ b/tests/modules/services/polybar/basic-configuration.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { config = { diff --git a/tests/modules/services/polybar/empty-configuration.nix b/tests/modules/services/polybar/empty-configuration.nix index 26350967..984e6b0c 100644 --- a/tests/modules/services/polybar/empty-configuration.nix +++ b/tests/modules/services/polybar/empty-configuration.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { config = { diff --git a/tests/modules/services/sxhkd/service.nix b/tests/modules/services/sxhkd/service.nix index 5f49f7a5..0d15b12d 100644 --- a/tests/modules/services/sxhkd/service.nix +++ b/tests/modules/services/sxhkd/service.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { xsession = { diff --git a/tests/modules/services/trayer/basic-configuration.nix b/tests/modules/services/trayer/basic-configuration.nix index 3020e631..2574fd36 100644 --- a/tests/modules/services/trayer/basic-configuration.nix +++ b/tests/modules/services/trayer/basic-configuration.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { config = { diff --git a/tests/modules/services/wlsunset/wlsunset-service.nix b/tests/modules/services/wlsunset/wlsunset-service.nix index e3f81650..27263a25 100644 --- a/tests/modules/services/wlsunset/wlsunset-service.nix +++ b/tests/modules/services/wlsunset/wlsunset-service.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { config = { diff --git a/tests/modules/services/xsettingsd/basic-configuration.nix b/tests/modules/services/xsettingsd/basic-configuration.nix index 8ea2ec78..2804f34a 100644 --- a/tests/modules/services/xsettingsd/basic-configuration.nix +++ b/tests/modules/services/xsettingsd/basic-configuration.nix @@ -1,4 +1,4 @@ -{ config, pkgs, ... }: +{ config, ... }: { config = { diff --git a/tests/modules/systemd/empty-user-config.nix b/tests/modules/systemd/empty-user-config.nix index 9e192ae4..e6d9b440 100644 --- a/tests/modules/systemd/empty-user-config.nix +++ b/tests/modules/systemd/empty-user-config.nix @@ -1,5 +1,3 @@ -{ pkgs, ... }: - { nmt.script = '' userConf=home-files/.config/systemd/user.conf