32 lines
660 B
Nix
32 lines
660 B
Nix
{
|
|
stdenv,
|
|
lib,
|
|
vimPlugins,
|
|
wrapNeovimUnstable,
|
|
lazyUtils,
|
|
}:
|
|
|
|
neovim-unwrapped:
|
|
|
|
let
|
|
wrapper =
|
|
{
|
|
luaRcContent ? "",
|
|
lazyConfig ? { },
|
|
lazyPlugins ? [ ],
|
|
vPlug ? vimPlugins,
|
|
...
|
|
}@attrs:
|
|
let
|
|
lazyUtilsOverride = lazyUtils.override { inherit vPlug; };
|
|
mergedLuaRcContent = # lua
|
|
''
|
|
${luaRcContent}
|
|
|
|
vim.opt.rtp:prepend("${lazyUtilsOverride.lazyPluginsJoin { inherit lazyConfig lazyPlugins; }}")
|
|
require("lazyWrapper")
|
|
'';
|
|
in
|
|
wrapNeovimUnstable neovim-unwrapped (attrs // { luaRcContent = mergedLuaRcContent; });
|
|
in
|
|
lib.makeOverridable wrapper
|