mirror of
https://github.com/nix-community/nixvim.git
synced 2025-06-21 00:25:42 +02:00
helpers/vim-plugin: mkPlugin -> mkVimPlugin
This commit is contained in:
parent
8f90372ee5
commit
a68ee73947
21 changed files with 21 additions and 21 deletions
|
@ -71,7 +71,7 @@ You will then need to add Nix options for all (or most) of the upstream plugin o
|
|||
These options should be in `camelCase` (whereas most plugins define their options in `snake_case`), and their names should match exactly (except the case) to the upstream names.
|
||||
There are a number of helpers to help you correctly implement them:
|
||||
|
||||
- `helpers.vim-plugin.mkPlugin`: This helper is useful for simple plugins that are configured through (vim) global variables.
|
||||
- `helpers.vim-plugin.mkVimPlugin`: This helper is useful for simple plugins that are configured through (vim) global variables.
|
||||
- `helpers.defaultNullOpts.{mkBool,mkInt,mkStr,...}`: This family of helpers takes a default value and a description, and sets the Nix default to `null`. These are the main functions you should use to define options.
|
||||
- `helpers.defaultNullOpts.mkNullable`: This takes a type, a default and a description. This is useful for more complex options.
|
||||
- `helpers.nixvimTypes.rawLua`: A type to represent raw lua code. The values are of the form `{ __raw = "<code>";}`. This should not be used if the option can only be raw lua code, `mkLua`/`mkLuaFn` should be used in this case.
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
mkPackageOption,
|
||||
}:
|
||||
with lib; {
|
||||
mkPlugin = {
|
||||
mkVimPlugin = {
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
with lib;
|
||||
(
|
||||
with (import ../helpers.nix {inherit lib;}).vim-plugin;
|
||||
mkPlugin args {
|
||||
mkVimPlugin args {
|
||||
name = "copilot-vim";
|
||||
description = "copilot.vim";
|
||||
package = pkgs.vimPlugins.copilot-vim;
|
||||
|
|
|
@ -14,7 +14,7 @@ in
|
|||
useDefaultPackage ? true,
|
||||
...
|
||||
}:
|
||||
mkPlugin {inherit lib config pkgs;} {
|
||||
mkVimPlugin {inherit lib config pkgs;} {
|
||||
inherit name;
|
||||
extraPlugins = extraPlugins ++ (lists.optional useDefaultPackage pkgs.vimPlugins.${name});
|
||||
description = "Enable ${name}";
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
in
|
||||
with helpers.vim-plugin;
|
||||
with lib;
|
||||
mkPlugin attrs {
|
||||
mkVimPlugin attrs {
|
||||
name = "fugitive";
|
||||
description = "Enable vim-fugitive";
|
||||
package = pkgs.vimPlugins.vim-fugitive;
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
} @ args:
|
||||
with lib;
|
||||
with (import ../helpers.nix {inherit lib;}).vim-plugin;
|
||||
mkPlugin args {
|
||||
mkVimPlugin args {
|
||||
name = "ledger";
|
||||
description = "ledger language features";
|
||||
package = pkgs.vimPlugins.vim-ledger;
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
} @ args:
|
||||
with lib;
|
||||
with (import ../helpers.nix {inherit lib;}).vim-plugin;
|
||||
mkPlugin args {
|
||||
mkVimPlugin args {
|
||||
name = "markdown-preview";
|
||||
description = "markdown-preview.nvim";
|
||||
package = pkgs.vimPlugins.markdown-preview-nvim;
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
in
|
||||
with helpers.vim-plugin;
|
||||
with lib;
|
||||
mkPlugin attrs {
|
||||
mkVimPlugin attrs {
|
||||
name = "nix";
|
||||
description = "Enable nix";
|
||||
package = pkgs.vimPlugins.vim-nix;
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
} @ args:
|
||||
with lib;
|
||||
with (import ../helpers.nix {inherit lib;}).vim-plugin;
|
||||
mkPlugin args {
|
||||
mkVimPlugin args {
|
||||
name = "tagbar";
|
||||
package = pkgs.vimPlugins.tagbar;
|
||||
globalPrefix = "tagbar_";
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
in
|
||||
with lib;
|
||||
with helpers.vim-plugin;
|
||||
mkPlugin args {
|
||||
mkVimPlugin args {
|
||||
name = "vim-slime";
|
||||
package = pkgs.vimPlugins.vim-slime;
|
||||
globalPrefix = "slime_";
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
in
|
||||
with helpers.vim-plugin;
|
||||
with lib;
|
||||
mkPlugin attrs {
|
||||
mkVimPlugin attrs {
|
||||
name = "zig";
|
||||
description = "Enable zig";
|
||||
package = pkgs.vimPlugins.zig-vim;
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
} @ args:
|
||||
with lib;
|
||||
with (import ../helpers.nix {inherit lib;}).vim-plugin;
|
||||
mkPlugin args {
|
||||
mkVimPlugin args {
|
||||
name = "airline";
|
||||
description = "vim-airline";
|
||||
package = pkgs.vimPlugins.vim-airline;
|
||||
|
|
|
@ -12,7 +12,7 @@ with lib; let
|
|||
either strInt (attrsOf (either strInt (attrsOf strInt)));
|
||||
in
|
||||
with helpers.vim-plugin;
|
||||
mkPlugin attrs {
|
||||
mkVimPlugin attrs {
|
||||
name = "emmet";
|
||||
description = "Enable emmet";
|
||||
package = pkgs.vimPlugins.emmet-vim;
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
in
|
||||
with helpers.vim-plugin;
|
||||
with lib;
|
||||
mkPlugin attrs {
|
||||
mkVimPlugin attrs {
|
||||
name = "endwise";
|
||||
description = "Enable vim-endwise";
|
||||
package = pkgs.vimPlugins.vim-endwise;
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
in
|
||||
with helpers.vim-plugin;
|
||||
with lib;
|
||||
mkPlugin attrs {
|
||||
mkVimPlugin attrs {
|
||||
name = "goyo";
|
||||
description = "Enable goyo.vim";
|
||||
package = pkgs.vimPlugins.goyo-vim;
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
} @ args:
|
||||
with lib;
|
||||
with (import ../helpers.nix {inherit lib;}).vim-plugin;
|
||||
mkPlugin args {
|
||||
mkVimPlugin args {
|
||||
name = "instant";
|
||||
description = "instant.nvim";
|
||||
package = pkgs.vimPlugins.instant-nvim;
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
} @ args:
|
||||
with lib;
|
||||
with (import ../helpers.nix {inherit lib;}).vim-plugin;
|
||||
mkPlugin args {
|
||||
mkVimPlugin args {
|
||||
name = "magma-nvim";
|
||||
description = "magma-nvim";
|
||||
package = pkgs.vimPlugins.magma-nvim-goose;
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
in
|
||||
with lib;
|
||||
with helpers.vim-plugin;
|
||||
mkPlugin args {
|
||||
mkVimPlugin args {
|
||||
name = "molten";
|
||||
description = "molten-nvim";
|
||||
package = pkgs.vimPlugins.molten-nvim;
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
in
|
||||
with lib;
|
||||
with helpers.vim-plugin;
|
||||
mkPlugin args {
|
||||
mkVimPlugin args {
|
||||
name = "startify";
|
||||
description = "Enable startify";
|
||||
package = pkgs.vimPlugins.vim-startify;
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
in
|
||||
with helpers.vim-plugin;
|
||||
with lib;
|
||||
mkPlugin attrs {
|
||||
mkVimPlugin attrs {
|
||||
name = "surround";
|
||||
description = "Enable surround.vim";
|
||||
package = pkgs.vimPlugins.surround;
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
} @ args:
|
||||
with lib;
|
||||
with (import ../helpers.nix {inherit lib;}).vim-plugin;
|
||||
mkPlugin args {
|
||||
mkVimPlugin args {
|
||||
name = "undotree";
|
||||
package = pkgs.vimPlugins.undotree;
|
||||
globalPrefix = "undotree_";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue