mirror of
https://github.com/nix-community/nixvim.git
synced 2025-06-20 16:15:43 +02:00
treewide: luaName -> moduleName
Jus to closer align with its usage.
This commit is contained in:
parent
a7012e7864
commit
c37031d71f
23 changed files with 31 additions and 31 deletions
|
@ -73,12 +73,12 @@ A template plugin can be found in (plugins/TEMPLATE.nix)[https://github.com/nix-
|
|||
| **hasSettings** | Indicating whether the plugin has settings. A `settings` option will be created if true. | No | `true` |
|
||||
| **imports** | Additional modules to import. | No | `[]` |
|
||||
| **isColorscheme** | Indicating whether the plugin is a colorscheme. | No | `false` |
|
||||
| **luaName** | The Lua name for the plugin. | No | `name` parameter |
|
||||
| **moduleName** | The Lua name for the plugin. | No | `name` parameter |
|
||||
| **maintainers** | Maintainers for the plugin. | No | `[]` |
|
||||
| **optionsRenamedToSettings** | Options that have been renamed and move to the `settings` attribute. | No | `[]` |
|
||||
| **packPathName** | The name of the plugin directory in [packpath](https://neovim.io/doc/user/options.html#'packpath'), usually the plugin's github repo name. E.g. `"foo-bar.nvim"`. | No | `name` parameter |
|
||||
| **packPathName** | The name of the plugin directory in [packpath](https://neovim.io/doc/user/options.html#'packpath'), usually the plugin's github repo name. E.g. `"foo-bar.nvim"`. | No | `name` parameter |
|
||||
| **package** | The nixpkgs package attr for this plugin. Can be a string, a list of strings, a module option, or any derivation. For example, "foo-bar-nvim" for `pkgs.vimPlugins.foo-bar-nvim`, or `[ "hello" "world" ]` will be referenced as `pkgs.hello.world`. | No | `name` parameter |
|
||||
| **settingsDescription** | A description of the settings provided to the `setup` function. | No | `"Options provided to the require('${luaName}')${setup} function."` |
|
||||
| **settingsDescription** | A description of the settings provided to the `setup` function. | No | `"Options provided to the require('${moduleName}')${setup} function."` |
|
||||
| **settingsExample** | An example configuration for the plugin's settings. | No | `null` |
|
||||
| **settingsOptions** | Options representing the plugin's settings. This is optional because `settings` is a "freeform" option. See [Declaring plugin options](#declaring-plugin-options). | No | `{}` |
|
||||
| **setup** | The setup function for the plugin. | No | `".setup"` |
|
||||
|
@ -135,7 +135,7 @@ Such plugins are usually configured via vim globals, but often have no configura
|
|||
| **isColorscheme** | Flag to indicate if the plugin is a colorscheme. | No | `false` |
|
||||
| **maintainers** | The maintainers of the plugin. | No | `[]` |
|
||||
| **optionsRenamedToSettings** | List of options renamed to settings. | No | `[]` |
|
||||
| **packPathName** | The name of the plugin directory in [packpath](https://neovim.io/doc/user/options.html#'packpath'), usually the plugin's github repo name. E.g. `"foo-bar.vim"`. | No | `name` parameter |
|
||||
| **packPathName** | The name of the plugin directory in [packpath](https://neovim.io/doc/user/options.html#'packpath'), usually the plugin's github repo name. E.g. `"foo-bar.vim"`. | No | `name` parameter |
|
||||
| **package** | The nixpkgs package attr for this plugin. Can be a string, a list of strings, a module option, or any derivation. For example, "foo-bar-vim" for `pkgs.vimPlugins.foo-bar-vim`, or `[ "hello" "world" ]` will be referenced as `pkgs.hello.world`. | No | `name` parameter |
|
||||
| **settingsExample** | Example settings for the plugin. | No | `null` |
|
||||
| **settingsOptions** | Options representing the plugin's settings. This is optional because `settings` is a "freeform" option. See [Declaring plugin options](#declaring-plugin-options). | No | `{}` |
|
||||
|
|
|
@ -40,11 +40,11 @@
|
|||
package ? name,
|
||||
settingsOptions ? { },
|
||||
settingsExample ? null,
|
||||
settingsDescription ? "Options provided to the `require('${luaName}')${setup}` function.",
|
||||
settingsDescription ? "Options provided to the `require('${moduleName}')${setup}` function.",
|
||||
hasSettings ? true,
|
||||
extraOptions ? { },
|
||||
# config
|
||||
luaName ? name,
|
||||
moduleName ? name,
|
||||
setup ? ".setup",
|
||||
extraConfig ? cfg: { },
|
||||
extraPlugins ? [ ],
|
||||
|
@ -66,7 +66,7 @@
|
|||
opts = options.${namespace}.${name};
|
||||
|
||||
setupCode = ''
|
||||
require('${luaName}')${setup}(${
|
||||
require('${moduleName}')${setup}(${
|
||||
lib.optionalString (cfg ? settings) (lib.nixvim.toLuaObject cfg.settings)
|
||||
})
|
||||
'';
|
||||
|
|
|
@ -7,7 +7,7 @@ with lib;
|
|||
helpers.neovim-plugin.mkNeovimPlugin {
|
||||
name = "better-escape";
|
||||
packPathName = "better-escape.nvim";
|
||||
luaName = "better_escape";
|
||||
moduleName = "better_escape";
|
||||
package = "better-escape-nvim";
|
||||
|
||||
maintainers = [ maintainers.GaetanLepage ];
|
||||
|
|
|
@ -8,7 +8,7 @@ in
|
|||
lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
||||
name = "codeium-nvim";
|
||||
packPathName = "codeium.nvim";
|
||||
luaName = "codeium";
|
||||
moduleName = "codeium";
|
||||
|
||||
maintainers = with lib.maintainers; [
|
||||
GaetanLepage
|
||||
|
|
|
@ -7,7 +7,7 @@ with lib;
|
|||
helpers.neovim-plugin.mkNeovimPlugin {
|
||||
name = "comment";
|
||||
packPathName = "Comment.nvim";
|
||||
luaName = "Comment";
|
||||
moduleName = "Comment";
|
||||
package = "comment-nvim";
|
||||
|
||||
maintainers = [ maintainers.GaetanLepage ];
|
||||
|
|
|
@ -8,7 +8,7 @@ let
|
|||
in
|
||||
lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
||||
name = "conform-nvim";
|
||||
luaName = "conform";
|
||||
moduleName = "conform";
|
||||
packPathName = "conform.nvim";
|
||||
|
||||
maintainers = [ lib.maintainers.khaneliman ];
|
||||
|
|
|
@ -7,7 +7,7 @@ with lib;
|
|||
helpers.neovim-plugin.mkNeovimPlugin {
|
||||
name = "copilot-chat";
|
||||
packPathName = "CopilotChat.nvim";
|
||||
luaName = "CopilotChat";
|
||||
moduleName = "CopilotChat";
|
||||
package = "CopilotChat-nvim";
|
||||
|
||||
maintainers = [ maintainers.GaetanLepage ];
|
||||
|
|
|
@ -7,7 +7,7 @@ with lib;
|
|||
helpers.neovim-plugin.mkNeovimPlugin {
|
||||
name = "indent-blankline";
|
||||
packPathName = "indent-blankline.nvim";
|
||||
luaName = "ibl";
|
||||
moduleName = "ibl";
|
||||
package = "indent-blankline-nvim";
|
||||
|
||||
maintainers = [ maintainers.GaetanLepage ];
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
with lib;
|
||||
helpers.neovim-plugin.mkNeovimPlugin {
|
||||
name = "lsp-lines";
|
||||
luaName = "lsp_lines";
|
||||
moduleName = "lsp_lines";
|
||||
packPathName = "lsp_lines.nvim";
|
||||
package = "lsp_lines-nvim";
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@ lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
|||
name = "lsp-signature";
|
||||
packPathName = "lsp_signature.nvim";
|
||||
package = "lsp_signature-nvim";
|
||||
luaName = "lsp_signature";
|
||||
moduleName = "lsp_signature";
|
||||
|
||||
maintainers = [ lib.maintainers.wadsaek ];
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@ in
|
|||
lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
||||
name = "navic";
|
||||
packPathName = "nvim-navic";
|
||||
luaName = "nvim-navic";
|
||||
moduleName = "nvim-navic";
|
||||
package = "nvim-navic";
|
||||
|
||||
maintainers = [ lib.maintainers.khaneliman ];
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
||||
name = "none-ls";
|
||||
packPathName = "none-ls.nvim";
|
||||
luaName = "null-ls";
|
||||
moduleName = "null-ls";
|
||||
package = "none-ls-nvim";
|
||||
|
||||
maintainers = [ lib.maintainers.MattSturgeon ];
|
||||
|
|
|
@ -8,7 +8,7 @@ let
|
|||
in
|
||||
lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
||||
name = "nvim-snippets";
|
||||
luaName = "snippets";
|
||||
moduleName = "snippets";
|
||||
|
||||
maintainers = [ lib.maintainers.psfloyd ];
|
||||
|
||||
|
|
|
@ -7,7 +7,7 @@ let
|
|||
in
|
||||
lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
||||
name = "nvim-ufo";
|
||||
luaName = "ufo";
|
||||
moduleName = "ufo";
|
||||
package = "nvim-ufo";
|
||||
|
||||
maintainers = [ lib.maintainers.khaneliman ];
|
||||
|
|
|
@ -9,7 +9,7 @@ in
|
|||
lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
||||
name = "project-nvim";
|
||||
packPathName = "project.nvim";
|
||||
luaName = "project_nvim";
|
||||
moduleName = "project_nvim";
|
||||
|
||||
maintainers = [ lib.maintainers.khaneliman ];
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@ in
|
|||
lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
||||
name = "rest";
|
||||
packPathName = "rest.nvim";
|
||||
luaName = "rest-nvim";
|
||||
moduleName = "rest-nvim";
|
||||
package = "rest-nvim";
|
||||
|
||||
maintainers = [ lib.maintainers.GaetanLepage ];
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
||||
name = "sqlite-lua";
|
||||
packPathName = "sqlite.lua";
|
||||
luaName = "sqlite.lua";
|
||||
moduleName = "sqlite.lua";
|
||||
package = "sqlite-lua";
|
||||
|
||||
maintainers = [ lib.maintainers.khaneliman ];
|
||||
|
|
|
@ -9,7 +9,7 @@ with lib;
|
|||
helpers.neovim-plugin.mkNeovimPlugin {
|
||||
name = "treesitter";
|
||||
packPathName = "nvim-treesitter";
|
||||
luaName = "nvim-treesitter.configs";
|
||||
moduleName = "nvim-treesitter.configs";
|
||||
package = "nvim-treesitter";
|
||||
|
||||
description = ''
|
||||
|
|
|
@ -8,7 +8,7 @@ with lib;
|
|||
helpers.neovim-plugin.mkNeovimPlugin {
|
||||
name = "ts-autotag";
|
||||
packPathName = "nvim-ts-autotag";
|
||||
luaName = "nvim-ts-autotag";
|
||||
moduleName = "nvim-ts-autotag";
|
||||
package = "nvim-ts-autotag";
|
||||
|
||||
maintainers = [ maintainers.GaetanLepage ];
|
||||
|
|
|
@ -5,7 +5,7 @@ in
|
|||
lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
||||
name = "web-devicons";
|
||||
packPathName = "nvim-web-devicons";
|
||||
luaName = "nvim-web-devicons";
|
||||
moduleName = "nvim-web-devicons";
|
||||
package = "nvim-web-devicons";
|
||||
|
||||
maintainers = [ lib.maintainers.refaelsh ];
|
||||
|
|
|
@ -6,11 +6,11 @@ let
|
|||
inherit (lib.nixvim) defaultNullOpts toLuaObject;
|
||||
|
||||
name = "base16";
|
||||
luaName = "base16-colorscheme";
|
||||
moduleName = "base16-colorscheme";
|
||||
packPathName = "base16.nvim";
|
||||
in
|
||||
lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
||||
inherit name luaName packPathName;
|
||||
inherit name moduleName packPathName;
|
||||
setup = ".with_config";
|
||||
package = "base16-nvim";
|
||||
isColorscheme = true;
|
||||
|
@ -145,7 +145,7 @@ lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
|||
`:h nvim-base16-builtin-colorschemes` includes a full list of builtin themes,
|
||||
however the [plugin's source code] may be more up to date.
|
||||
|
||||
You can access `require('${luaName}')` as `base16` in any raw lua,
|
||||
You can access `require('${moduleName}')` as `base16` in any raw lua,
|
||||
for example, you could reuse some colors from the builtin colorschemes:
|
||||
|
||||
```nix
|
||||
|
@ -181,7 +181,7 @@ lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
|||
# See https://github.com/RRethy/base16-nvim/blob/6ac181b5733518040a33017dde654059cd771b7c/lua/base16-colorscheme.lua#L107-L125
|
||||
colorschemes.base16.luaConfig.content = ''
|
||||
do
|
||||
local base16 = require('${luaName}')
|
||||
local base16 = require('${moduleName}')
|
||||
base16.with_config(${toLuaObject cfg.settings})
|
||||
base16.setup(${toLuaObject cfg.colorscheme})
|
||||
end
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
||||
name = "dracula-nvim";
|
||||
packPathName = "dracula.nvim ";
|
||||
luaName = "dracula";
|
||||
moduleName = "dracula";
|
||||
colorscheme = "dracula";
|
||||
isColorscheme = true;
|
||||
|
||||
|
|
|
@ -7,7 +7,7 @@ let
|
|||
in
|
||||
lib.nixvim.neovim-plugin.mkNeovimPlugin {
|
||||
name = "modus";
|
||||
luaName = "modus-themes";
|
||||
moduleName = "modus-themes";
|
||||
packPathName = "modus-themes.nvim";
|
||||
package = "modus-themes-nvim";
|
||||
isColorscheme = true;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue