add descriptions for extraPlugins

This commit is contained in:
Ching Pei Yang 2023-07-26 15:27:34 +02:00
parent 5981cd14f8
commit 8d72e28c4d
2 changed files with 19 additions and 0 deletions

View file

@ -107,10 +107,13 @@ with lib; let
after = mkOption {
type = listOf str;
default = [];
description = "Setup this plugin after the following ones.";
};
setup = mkOption {
type = lines;
default = "";
description = "Lua code to run during setup.";
example = "require('aerial').setup {}";
};
};
};

View file

@ -161,6 +161,22 @@ in {
extraPlugins = mkOption {
type = types.attrsOf nvim.types.extraPluginType;
default = {};
description = ''
List of plugins and related config.
Note that these are setup after builtin plugins.
'';
example = literalExpression ''
with pkgs.vimPlugins; {
aerial = {
package = aerial-nvim;
setup = "require('aerial').setup {}";
};
harpoon = {
package = harpoon;
setup = "require('harpoon').setup {}";
after = ["aerial"];
};
}'';
};
globals = mkOption {