1
- *lazy.nvim.txt* For Neovim >= 0.8.0 Last change: 2023 October 10
1
+ *lazy.nvim.txt* For Neovim >= 0.8.0 Last change: 2023 October 11
2
2
3
3
==============================================================================
4
4
Table of Contents *lazy.nvim-table-of-contents*
@@ -103,50 +103,50 @@ It is recommended to run `:checkhealth lazy` after installation.
103
103
104
104
PLUGIN SPEC *lazy.nvim-lazy.nvim-plugin-spec*
105
105
106
- ----------------------------------------------------------------------------------------------------------------------------------
106
+ --------------------------------------------------------------------------------------------------------------------------------
107
107
Property Type Description
108
- -------------- ------------------------------------------------------------ ------------------------------------------------------
108
+ -------------- ------------------------------------------------------------ ----------------------------------------------------
109
109
[1] string? Short plugin url. Will be expanded using
110
110
config.git.url_format
111
111
112
112
dir string? A directory pointing to a local plugin
113
113
114
114
url string? A custom git url where the plugin is hosted
115
115
116
- name string? A custom name for the plugin used for the local plugin
117
- directory and as the display name
116
+ name string? A custom name for the plugin used for the local
117
+ plugin directory and as the display name
118
118
119
119
dev boolean? When true, a local plugin directory will be used
120
120
instead. See config.dev
121
121
122
- lazy boolean? When true, the plugin will only be loaded when needed.
123
- Lazy-loaded plugins are automatically loaded when
124
- their Lua modules are required, or when one of the
125
- lazy-loading handlers triggers
122
+ lazy boolean? When true, the plugin will only be loaded when
123
+ needed. Lazy-loaded plugins are automatically loaded
124
+ when their Lua modules are required, or when one of
125
+ the lazy-loading handlers triggers
126
126
127
127
enabled boolean? or fun():boolean When false, or if the function returns false, then
128
128
this plugin will not be included in the spec
129
129
130
130
cond boolean? or fun(LazyPlugin):boolean When false, or if the function returns false, then
131
- this plugin will not be loaded. Useful to disable some
132
- plugins in vscode, or firenvim for example.
131
+ this plugin will not be loaded. Useful to disable
132
+ some plugins in vscode, or firenvim for example.
133
133
134
- dependencies LazySpec[] A list of plugin names or plugin specs that should be
135
- loaded when the plugin loads. Dependencies are always
136
- lazy-loaded unless specified otherwise. When
137
- specifying a name, make sure the plugin spec has been
138
- defined somewhere else.
134
+ dependencies LazySpec[] A list of plugin names or plugin specs that should
135
+ be loaded when the plugin loads. Dependencies are
136
+ always lazy-loaded unless specified otherwise. When
137
+ specifying a name, make sure the plugin spec has
138
+ been defined somewhere else.
139
139
140
140
init fun(LazyPlugin) init functions are always executed during startup
141
141
142
142
opts table or fun(LazyPlugin, opts:table) opts should be a table (will be merged with parent
143
143
specs), return a table (replaces parent specs) or
144
- should change a table. The table will be passed to the
145
- Plugin.config() function. Setting this value will
146
- imply Plugin.config()
144
+ should change a table. The table will be passed to
145
+ the Plugin.config() function. Setting this value
146
+ will imply Plugin.config()
147
147
148
- config fun(LazyPlugin, opts:table) or true config is executed when the plugin loads. The default
149
- implementation will automatically run
148
+ config fun(LazyPlugin, opts:table) or true config is executed when the plugin loads. The
149
+ default implementation will automatically run
150
150
require(MAIN).setup(opts). Lazy uses several
151
151
heuristics to determine the plugin’s MAIN module
152
152
automatically based on the plugin’s name. See also
@@ -160,28 +160,31 @@ PLUGIN SPEC *lazy.nvim-lazy.nvim-plugin-spec*
160
160
build fun(LazyPlugin) or string or a list of build commands build is executed when a plugin is installed or
161
161
updated. Before running build, a plugin is first
162
162
loaded. If it’s a string it will be ran as a shell
163
- command. When prefixed with : it is a Neovim command.
164
- You can also specify a list to executed multiple build
165
- commands. Some plugins provide their own build.lua
166
- which is automatically used by lazy. So no need to
167
- specify a build step for those plugins.
163
+ command. When prefixed with : it is a Neovim
164
+ command. You can also specify a list to executed
165
+ multiple build commands. Some plugins provide their
166
+ own build.lua which is automatically used by lazy.
167
+ So no need to specify a build step for those
168
+ plugins.
168
169
169
170
branch string? Branch of the repository
170
171
171
172
tag string? Tag of the repository
172
173
173
174
commit string? Commit of the repository
174
175
175
- version string? or false to override the default Version to use from the repository. Full Semver ranges
176
- are supported
176
+ version string? or false to override the default Version to use from the repository. Full Semver
177
+ ranges are supported
177
178
178
- pin boolean? When true, this plugin will not be included in updates
179
+ pin boolean? When true, this plugin will not be included in
180
+ updates
179
181
180
182
submodules boolean? When false, git submodules will not be fetched.
181
183
Defaults to true
182
184
183
185
event string? or string[] or Lazy-load on event. Events can be specified as
184
- fun(self:LazyPlugin, event:string[]):string[] BufEnter or with a pattern like BufEnter *.lua
186
+ fun(self:LazyPlugin, event:string[]):string[] or BufEnter or with a pattern like BufEnter *.lua
187
+ {event:string[]\| string, pattern?:string[]\ | string}
185
188
186
189
cmd string? or string[] or Lazy-load on command
187
190
fun(self:LazyPlugin, cmd:string[]):string[]
@@ -196,17 +199,17 @@ PLUGIN SPEC *lazy.nvim-lazy.nvim-plugin-spec*
196
199
required somewhere
197
200
198
201
priority number? Only useful for start plugins (lazy=false) to force
199
- loading certain plugins first. Default priority is 50.
200
- It’s recommended to set this to a high number for
201
- colorschemes.
202
+ loading certain plugins first. Default priority is
203
+ 50. It’s recommended to set this to a high number
204
+ for colorschemes.
202
205
203
206
optional boolean? When a spec is tagged optional, it will only be
204
207
included in the final spec, when the same plugin has
205
208
been specified at least once somewhere else without
206
- optional. This is mainly useful for Neovim distros, to
207
- allow setting options on plugins that may/may not be
208
- part of the user’s plugins
209
- ----------------------------------------------------------------------------------------------------------------------------------
209
+ optional. This is mainly useful for Neovim distros,
210
+ to allow setting options on plugins that may/may not
211
+ be part of the user’s plugins
212
+ --------------------------------------------------------------------------------------------------------------------------------
210
213
211
214
LAZY LOADING ~
212
215
0 commit comments