diff options
author | Matthieu Coudron <mcoudron@hotmail.com> | 2023-06-27 11:00:51 +0200 |
---|---|---|
committer | Matthieu Coudron <teto@users.noreply.github.com> | 2023-07-06 01:32:01 +0200 |
commit | 2473b4462700051bdd499170be05832d2801b446 (patch) | |
tree | 348ee73916e04a62c0f5367a6ba1e53d7f82eb0f /pkgs/applications/editors/neovim | |
parent | 1348fc1c95914c7f6d4dc9c666ca4efc28c15089 (diff) | |
download | nixlib-2473b4462700051bdd499170be05832d2801b446.tar nixlib-2473b4462700051bdd499170be05832d2801b446.tar.gz nixlib-2473b4462700051bdd499170be05832d2801b446.tar.bz2 nixlib-2473b4462700051bdd499170be05832d2801b446.tar.lz nixlib-2473b4462700051bdd499170be05832d2801b446.tar.xz nixlib-2473b4462700051bdd499170be05832d2801b446.tar.zst nixlib-2473b4462700051bdd499170be05832d2801b446.zip |
neovim: add perl to supported providers
false by default. I noticed checkhealth complaining about it Which made me realize the providers ignored user config and were always using default config, hence the backport.
Diffstat (limited to 'pkgs/applications/editors/neovim')
-rw-r--r-- | pkgs/applications/editors/neovim/utils.nix | 3 | ||||
-rw-r--r-- | pkgs/applications/editors/neovim/wrapper.nix | 13 |
2 files changed, 13 insertions, 3 deletions
diff --git a/pkgs/applications/editors/neovim/utils.nix b/pkgs/applications/editors/neovim/utils.nix index 038b9cc011ce..865c52193281 100644 --- a/pkgs/applications/editors/neovim/utils.nix +++ b/pkgs/applications/editors/neovim/utils.nix @@ -175,6 +175,8 @@ let withPython3 ? true , withNodeJs ? false , withRuby ? true + # perl is problematic https://github.com/NixOS/nixpkgs/issues/132368 + , withPerl ? false # so that we can pass the full neovim config while ignoring it , ... @@ -184,6 +186,7 @@ let python = false; python3 = withPython3; ruby = withRuby; + perl = withPerl; }; genProviderCommand = prog: withProg: diff --git a/pkgs/applications/editors/neovim/wrapper.nix b/pkgs/applications/editors/neovim/wrapper.nix index 887d647e2383..d302b83f44f0 100644 --- a/pkgs/applications/editors/neovim/wrapper.nix +++ b/pkgs/applications/editors/neovim/wrapper.nix @@ -6,6 +6,7 @@ , callPackage , neovimUtils , vimUtils +, perl }: neovim: @@ -19,6 +20,7 @@ let , withPython2 ? false , withPython3 ? true, python3Env ? python3 , withNodeJs ? false + , withPerl ? false , rubyEnv ? null , vimAlias ? false , viAlias ? false @@ -32,7 +34,7 @@ let # entry to load in packpath , packpathDirs , ... - }@args: + }: let wrapperArgsStr = if lib.isString wrapperArgs then wrapperArgs else lib.escapeShellArgs wrapperArgs; @@ -50,8 +52,10 @@ let ] ; - providerLuaRc = neovimUtils.generateProviderRc args; - # providerLuaRc = "toto"; + providerLuaRc = neovimUtils.generateProviderRc { + inherit withPython3 withNodeJs withPerl; + withRuby = rubyEnv != null; + }; # If configure != {}, we can't generate the rplugin.vim file with e.g # NVIM_SYSTEM_RPLUGIN_MANIFEST *and* NVIM_RPLUGIN_MANIFEST env vars set in @@ -86,6 +90,9 @@ let + lib.optionalString withNodeJs '' ln -s ${nodePackages.neovim}/bin/neovim-node-host $out/bin/nvim-node '' + + lib.optionalString withPerl '' + ln -s ${perl}/bin/perl $out/bin/nvim-perl + '' + lib.optionalString vimAlias '' ln -s $out/bin/nvim $out/bin/vim '' |