lib/neovim-plugin: allow disabling installPackage

Some plugins may wish to handle package installation themselves.
This commit is contained in:
Matt Sturgeon 2024-07-06 12:32:54 +01:00
parent 04a255ed7e
commit 843fb302eb
No known key found for this signature in database
GPG key ID: 4F91844CED1A8299

View file

@ -47,6 +47,7 @@ with lib;
extraPlugins ? [ ],
extraPackages ? [ ],
callSetup ? true,
installPackage ? true,
}:
let
namespace = if isColorscheme then "colorschemes" else "plugins";
@ -107,7 +108,7 @@ with lib;
in
mkIf cfg.enable (mkMerge [
{
extraPlugins = [ cfg.package ] ++ extraPlugins;
extraPlugins = (optional installPackage cfg.package) ++ extraPlugins;
inherit extraPackages;
${extraConfigNamespace} = optionalString callSetup ''