mirror of
https://github.com/nix-community/nixvim.git
synced 2025-06-21 00:25:42 +02:00
modules/output: obtain plugin configs from wrapped neovim
The official method for obtaining the generated initRc content is from wrapped neovim rather than from makeNeovimConfig helper. To use this approach: first wrap neovim with the generated config, then override it with our wrapperArgs.
This commit is contained in:
parent
ba77e88740
commit
767eb62f48
2 changed files with 12 additions and 10 deletions
|
@ -285,8 +285,10 @@ in
|
|||
}
|
||||
);
|
||||
|
||||
wrappedNeovim' = pkgs.wrapNeovimUnstable package neovimConfig;
|
||||
|
||||
customRC = helpers.concatNonEmptyLines [
|
||||
(helpers.wrapVimscriptForLua neovimConfig.neovimRcContent)
|
||||
(helpers.wrapVimscriptForLua wrappedNeovim'.initRc)
|
||||
config.content
|
||||
];
|
||||
|
||||
|
@ -330,13 +332,13 @@ in
|
|||
else
|
||||
config.package;
|
||||
|
||||
wrappedNeovim = pkgs.wrapNeovimUnstable package (
|
||||
neovimConfig
|
||||
// {
|
||||
wrapperArgs = lib.escapeShellArgs neovimConfig.wrapperArgs + " " + extraWrapperArgs;
|
||||
wrapRc = false;
|
||||
}
|
||||
);
|
||||
wrappedNeovim = wrappedNeovim'.override (prev: {
|
||||
wrapperArgs =
|
||||
(if lib.isString prev.wrapperArgs then prev.wrapperArgs else lib.escapeShellArgs prev.wrapperArgs)
|
||||
+ " "
|
||||
+ extraWrapperArgs;
|
||||
wrapRc = false;
|
||||
});
|
||||
in
|
||||
{
|
||||
build = {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue