refactor(lsp): use autocmd api (#19407)

* refactor(lsp): use autocmd api

* refactor(lsp): inline BufWritePost and VimLeavePre callbacks
This commit is contained in:
ii14
2022-07-17 19:13:33 +02:00
committed by GitHub
parent ff35d7a4b9
commit 13abe20b5f
4 changed files with 70 additions and 66 deletions

View File

@@ -61,7 +61,7 @@ local function progress_handler(_, result, ctx, _)
client.messages.progress[token].done = true
end
api.nvim_command('doautocmd <nomodeline> User LspProgressUpdate')
api.nvim_exec_autocmds('User', { pattern = 'LspProgressUpdate', modeline = false })
end
--see: https://microsoft.github.io/language-server-protocol/specifications/specification-current/#progress