diff --git a/pkgs/applications/editors/neovim/tests.nix b/pkgs/applications/editors/neovim/tests.nix index 085fceac1108..1e46a59f563b 100644 --- a/pkgs/applications/editors/neovim/tests.nix +++ b/pkgs/applications/editors/neovim/tests.nix @@ -87,7 +87,7 @@ rec { nvim_with_plug = neovim.override { extraName = "-with-plug"; configure.plug.plugins = with pkgs.vimPlugins; [ - base16-vim + (base16-vim.overrideAttrs(old: { pname = old.pname + "-unique-for-tests-please-dont-use"; })) ]; configure.customRC = '' color base16-tomorrow-night @@ -97,7 +97,7 @@ rec { run_nvim_with_plug = runTest nvim_with_plug '' export HOME=$TMPDIR - ${nvim_with_plug}/bin/nvim -i NONE -c 'color base16-tomorrow-night' +quit! + ${nvim_with_plug}/bin/nvim -i NONE -c 'color base16-tomorrow-night' +quit! -e ''; diff --git a/pkgs/misc/vim-plugins/vim-utils.nix b/pkgs/misc/vim-plugins/vim-utils.nix index 60b9b60806d5..01c32b2a3996 100644 --- a/pkgs/misc/vim-plugins/vim-utils.nix +++ b/pkgs/misc/vim-plugins/vim-utils.nix @@ -292,14 +292,12 @@ let /* vim-plug is an extremely popular vim plugin manager. */ - /* Remove repeated "/." suffixes from a path */ - stripDots = path: lib.head (builtins.split "(/\\.)*$" path); plugImpl = ('' source ${vimPlugins.vim-plug.rtp}/plug.vim silent! call plug#begin('/dev/null') - '' + (lib.concatMapStringsSep "\n" (pkg: "Plug '${stripDots pkg.rtp}'") plug.plugins) + '' + '' + (lib.concatMapStringsSep "\n" (pkg: "Plug '${pkg.rtp}'") plug.plugins) + '' call plug#end() '');