neovim: set packpath only if there are packages

part of the work to automatically disable the generation of init.vim when unnecessary
master
Matthieu Coudron 2021-06-03 20:27:23 +02:00 committed by Matthieu Coudron
parent 9f955ff079
commit 1d1c6753c6
1 changed files with 2 additions and 2 deletions

View File

@ -184,7 +184,7 @@ let
rtpPath = "share/vim-plugins";
nativeImpl = packages: lib.optionalString (packages != null)
nativeImpl = packages:
(let
link = (packageName: dir: pluginPath: "ln -sf ${pluginPath}/share/vim-plugins/* $out/pack/${packageName}/${dir}");
packageLinks = (packageName: {start ? [], opt ? []}:
@ -340,8 +340,8 @@ let
entries = [
beforePlugins
vamImpl
(nativeImpl packages)
]
++ lib.optional (packages != null && packages != []) (nativeImpl packages)
++ lib.optional (pathogen != null) pathogenImpl
++ lib.optional (plug != null) plugImpl
++ [ customRC ];