From 0884d6c6e47e75bdd1c40045d4d73e7f6c8e5cb8 Mon Sep 17 00:00:00 2001 From: Matthieu Coudron Date: Fri, 26 Aug 2022 22:11:34 +0200 Subject: [PATCH] programs.neovim: remove 'configure' setting (#3177) everything is now covered by other settings that are more user friendly than this big opaque attrset. Also 'configure' wont do anything with nixpkgs-unstable the way HM configures neovim. so no need to keep it, the deprecation warning is > 1 year old. --- modules/programs/neovim.nix | 49 ++++++------------------------------- 1 file changed, 8 insertions(+), 41 deletions(-) diff --git a/modules/programs/neovim.nix b/modules/programs/neovim.nix index 50f30d922..7123f07a4 100644 --- a/modules/programs/neovim.nix +++ b/modules/programs/neovim.nix @@ -99,6 +99,14 @@ in { "Python2 support has been removed from neovim.") (mkRemovedOptionModule [ "programs" "neovim" "extraPythonPackages" ] "Python2 support has been removed from neovim.") + (mkRemovedOptionModule [ "programs" "neovim" "configure" ] '' + programs.neovim.configure is deprecated. + Other programs.neovim options can override its settings or ignore them. + Please use the other options at your disposal: + configure.packages.*.opt -> programs.neovim.plugins = [ { plugin = ...; optional = true; }] + configure.packages.*.start -> programs.neovim.plugins = [ { plugin = ...; }] + configure.customRC -> programs.neovim.extraConfig + '') ]; options = { @@ -221,35 +229,6 @@ in { description = "Resulting customized neovim package."; }; - configure = mkOption { - type = types.attrsOf types.anything; - default = { }; - example = literalExpression '' - configure = { - customRC = $'''' - " here your custom configuration goes! - $''''; - packages.myVimPackage = with pkgs.vimPlugins; { - # loaded on launch - start = [ fugitive ]; - # manually loadable by calling `:packadd $plugin-name` - opt = [ ]; - }; - }; - ''; - description = '' - Deprecated. Please use the other options. - - Generate your init file from your list of plugins and custom commands, - and loads it from the store via nvim -u /nix/store/hash-vimrc - - - - This option is mutually exclusive with extraConfig - and plugins. - ''; - }; - extraConfig = mkOption { type = types.lines; default = ""; @@ -258,10 +237,6 @@ in { ''; description = '' Custom vimrc lines. - - - - This option is mutually exclusive with configure. ''; }; @@ -372,14 +347,6 @@ in { }; in mkIf cfg.enable { - warnings = optional (cfg.configure != { }) '' - programs.neovim.configure is deprecated. - Other programs.neovim options can override its settings or ignore them. - Please use the other options at your disposal: - configure.packages.*.opt -> programs.neovim.plugins = [ { plugin = ...; optional = true; }] - configure.packages.*.start -> programs.neovim.plugins = [ { plugin = ...; }] - configure.customRC -> programs.neovim.extraConfig - ''; programs.neovim.generatedConfigViml = neovimConfig.neovimRcContent;