mirror of
https://github.com/neovim/neovim.git
synced 2026-04-19 22:10:45 +00:00
docs(api): nvim_exec_autocmds() default "pattern"
Problem: nvim_exec_autocmds() documentation incorrectly describes the default for "pattern" as *, when it's actually the current file name (like :doautocmd). Solution: correct it. Add a test.
This commit is contained in:
2
runtime/lua/vim/_meta/api.lua
generated
2
runtime/lua/vim/_meta/api.lua
generated
@@ -1224,7 +1224,7 @@ function vim.api.nvim_exec2(src, opts) end
|
||||
--- @param event vim.api.keyset.events|vim.api.keyset.events[] Event(s) to execute.
|
||||
--- @param opts vim.api.keyset.exec_autocmds Optional filters:
|
||||
--- - group (`string|integer?`) Group name or id to match against. `autocmd-groups`.
|
||||
--- - pattern (`string|array?`, default: "*") `autocmd-pattern`. Not allowed with {buffer}.
|
||||
--- - pattern (`string|array?`, default: current file name) `autocmd-pattern`. Not allowed with {buffer}.
|
||||
--- - buffer (`integer?`) Buffer id `autocmd-buflocal`. Not allowed with {pattern}.
|
||||
--- - modeline (`boolean?`, default: true) Process the modeline after the autocommands
|
||||
--- [<nomodeline>].
|
||||
|
||||
Reference in New Issue
Block a user