diff options
author | Matthieu Coudron <teto@users.noreply.github.com> | 2022-06-13 15:25:46 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-06-13 15:25:46 +0200 |
commit | a1ad23574310f0ca7aedd916192855a3e2a46729 (patch) | |
tree | f265a6da7e929cc526ad891cf77160faa886b79a | |
parent | 5ed22350508f1fd0b79d56f39552a4ea5c163c2e (diff) |
vimUtils: deprecate configure.pathogen (#154814)
pathogen does not bring any value compared to vim native packages so remove it to ease maintainance burden.
-rw-r--r-- | doc/languages-frameworks/vim.section.md | 3 | ||||
-rw-r--r-- | nixos/doc/manual/from_md/release-notes/rl-2211.section.xml | 8 | ||||
-rw-r--r-- | nixos/doc/manual/release-notes/rl-2211.section.md | 3 | ||||
-rw-r--r-- | pkgs/applications/editors/neovim/tests.nix | 4 | ||||
-rw-r--r-- | pkgs/applications/editors/vim/plugins/vim-utils.nix | 19 | ||||
-rw-r--r-- | pkgs/test/vim/default.nix | 5 |
6 files changed, 18 insertions, 24 deletions
diff --git a/doc/languages-frameworks/vim.section.md b/doc/languages-frameworks/vim.section.md index 563fdf45a8611..6d7efe455b136 100644 --- a/doc/languages-frameworks/vim.section.md +++ b/doc/languages-frameworks/vim.section.md @@ -277,9 +277,6 @@ my-vim = copy paste output2 here ]; - # Pathogen would be - # vimrcConfig.pathogen.knownPlugins = plugins; # plugins - # vimrcConfig.pathogen.pluginNames = ["tlib"]; }; ``` diff --git a/nixos/doc/manual/from_md/release-notes/rl-2211.section.xml b/nixos/doc/manual/from_md/release-notes/rl-2211.section.xml index 9580006878108..79bba37a13589 100644 --- a/nixos/doc/manual/from_md/release-notes/rl-2211.section.xml +++ b/nixos/doc/manual/from_md/release-notes/rl-2211.section.xml @@ -121,6 +121,14 @@ this version for the entire lifecycle of the 22.11 release. </para> </listitem> + <listitem> + <para> + (Neo)Vim can not be configured with + <literal>configure.pathogen</literal> anymore to reduce + maintainance burden. Use <literal>configure.packages</literal> + instead. + </para> + </listitem> </itemizedlist> </section> <section xml:id="sec-release-22.11-notable-changes"> diff --git a/nixos/doc/manual/release-notes/rl-2211.section.md b/nixos/doc/manual/release-notes/rl-2211.section.md index 1a14885ed8c38..50bf15ca197d8 100644 --- a/nixos/doc/manual/release-notes/rl-2211.section.md +++ b/nixos/doc/manual/release-notes/rl-2211.section.md @@ -50,6 +50,9 @@ In addition to numerous new and upgraded packages, this release has the followin - PHP 7.4 is no longer supported due to upstream not supporting this version for the entire lifecycle of the 22.11 release. +- (Neo)Vim can not be configured with `configure.pathogen` anymore to reduce maintainance burden. +Use `configure.packages` instead. + <!-- To avoid merge conflicts, consider adding your item at an arbitrary place in the list instead. --> ## Other Notable Changes {#sec-release-22.11-notable-changes} diff --git a/pkgs/applications/editors/neovim/tests.nix b/pkgs/applications/editors/neovim/tests.nix index 1e46a59f563bd..3163041dabfef 100644 --- a/pkgs/applications/editors/neovim/tests.nix +++ b/pkgs/applications/editors/neovim/tests.nix @@ -150,8 +150,8 @@ rec { # and do `:call deoplete#enable()`. It will print an error if the remote # plugin is not registered. test_nvim_with_remote_plugin = neovim.override { - extraName = "-pathogen-remote"; - configure.pathogen.pluginNames = with vimPlugins; [ deoplete-nvim ]; + extraName = "-remote"; + configure.packages.foo.start = with vimPlugins; [ deoplete-nvim ]; }; # only neovim makes use of `requiredPlugins`, test this here diff --git a/pkgs/applications/editors/vim/plugins/vim-utils.nix b/pkgs/applications/editors/vim/plugins/vim-utils.nix index 14dbc43d3cd97..1170771c62a18 100644 --- a/pkgs/applications/editors/vim/plugins/vim-utils.nix +++ b/pkgs/applications/editors/vim/plugins/vim-utils.nix @@ -51,9 +51,6 @@ vim-with-plugins in PATH: # full documentation at github.com/MarcWeber/vim-addon-manager ]; - # there is a pathogen implementation as well, but its startup is slower and [VAM] has more feature - # vimrcConfig.pathogen.knownPlugins = vimPlugins; # optional - # vimrcConfig.pathogen.pluginNames = ["vim-addon-nix"]; }; WHAT IS A VIM PLUGIN? @@ -103,7 +100,7 @@ It might happen than a plugin is not known by vim-pi yet. We encourage you to contribute to vim-pi so that plugins can be updated automatically. -CREATING DERVITATIONS AUTOMATICALLY BY PLUGIN NAME +CREATING DERIVATIONS AUTOMATICALLY BY PLUGIN NAME ================================================== Most convenient is to use a ~/.vim-scripts file putting a plugin name into each line as documented by [VAM]'s README.md @@ -277,24 +274,18 @@ let }: let - /* pathogen mostly can set &rtp at startup time. Its used very commonly. + /* pathogen mostly can set &rtp at startup time. Deprecated. */ pathogenImpl = let knownPlugins = pathogen.knownPlugins or vimPlugins; plugins = findDependenciesRecursively (map (pluginToDrv knownPlugins) pathogen.pluginNames); - pluginsEnv = buildEnv { - name = "pathogen-plugin-env"; - paths = map (x: "${x}/${rtpPath}") plugins; + pathogenPackages.pathogen = lib.warn "'pathogen' attribute is deprecated. Use 'packages' instead in your vim configuration" { + start = plugins; }; in - '' - let &rtp.=(empty(&rtp)?"":',')."${vimPlugins.vim-pathogen.rtp}" - execute pathogen#infect('${pluginsEnv}/{}') - - filetype indent plugin on | syn on - ''; + nativeImpl pathogenPackages; /* vim-plug is an extremely popular vim plugin manager. */ diff --git a/pkgs/test/vim/default.nix b/pkgs/test/vim/default.nix index 2beb75391eade..73c25ae20cb84 100644 --- a/pkgs/test/vim/default.nix +++ b/pkgs/test/vim/default.nix @@ -23,11 +23,6 @@ in vimrcConfig.vam.pluginDictionaries = [{name = "vim-nix"; }]; }; - test_vim_with_vim_nix_using_pathogen = vim_configurable.customize { - name = "vim-with-vim-addon-nix-using-pathogen"; - vimrcConfig.pathogen.pluginNames = [ "vim-nix" ]; - }; - test_vim_with_vim_nix_using_plug = vim_configurable.customize { name = "vim-with-vim-addon-nix-using-plug"; vimrcConfig.plug.plugins = with vimPlugins; [ vim-nix ]; |