diff options
| author | Lewis Russell <lewis6991@gmail.com> | 2024-10-24 12:11:27 +0100 |
|---|---|---|
| committer | Lewis Russell <me@lewisr.dev> | 2024-10-24 15:37:34 +0100 |
| commit | 7a7747f1e4d96aab53ff9c52d0c3492308c22c58 (patch) | |
| tree | 9818d40a7d1df837d6d8567ed521a0f53ca22c42 /runtime/doc | |
| parent | 39d79efa1e1e1e5c3476dee54cc2bc4abc725a8f (diff) | |
| download | rneovim-7a7747f1e4d96aab53ff9c52d0c3492308c22c58.tar.gz rneovim-7a7747f1e4d96aab53ff9c52d0c3492308c22c58.tar.bz2 rneovim-7a7747f1e4d96aab53ff9c52d0c3492308c22c58.zip | |
feat(lsp): deprecate execute_command with client:exec_cmd
Diffstat (limited to 'runtime/doc')
| -rw-r--r-- | runtime/doc/deprecated.txt | 1 | ||||
| -rw-r--r-- | runtime/doc/lsp.txt | 23 |
2 files changed, 15 insertions, 9 deletions
diff --git a/runtime/doc/deprecated.txt b/runtime/doc/deprecated.txt index 28771dbd28..7821878cfa 100644 --- a/runtime/doc/deprecated.txt +++ b/runtime/doc/deprecated.txt @@ -45,6 +45,7 @@ TREESITTER LSP • *vim.lsp.util.jump_to_location* +• *vim.lsp.buf.execute_command* Use |Client:exec_cmd()| instead. ------------------------------------------------------------------------------ DEPRECATED IN 0.10 *deprecated-0.10* diff --git a/runtime/doc/lsp.txt b/runtime/doc/lsp.txt index 4c0bd0c9ba..9b152702a1 100644 --- a/runtime/doc/lsp.txt +++ b/runtime/doc/lsp.txt @@ -1084,6 +1084,11 @@ Lua module: vim.lsp.client *lsp-client* • {is_stopped} (`fun(): boolean`) Checks whether a client is stopped. Returns: true if the client is fully stopped. + • {exec_cmd} (`fun(self: vim.lsp.Client, command: lsp.Command, context: {bufnr?: integer}?, handler: lsp.Handler?)`) + Execute a lsp command, either via client + command function (if available) or via + workspace/executeCommand (if supported by the + server) *vim.lsp.Client.Progress* Extends: |vim.Ringbuf| @@ -1213,6 +1218,15 @@ Lua module: vim.lsp.client *lsp-client* on initialization. +Client:exec_cmd({command}, {context}, {handler}) *Client:exec_cmd()* + Execute a lsp command, either via client command function (if available) + or via workspace/executeCommand (if supported by the server) + + Parameters: ~ + • {command} (`lsp.Command`) + • {context} (`{bufnr?: integer}?`) + • {handler} (`lsp.Handler?`) only called if a server command + ============================================================================== Lua module: vim.lsp.buf *lsp-buf* @@ -1344,15 +1358,6 @@ document_symbol({opts}) *vim.lsp.buf.document_symbol()* Parameters: ~ • {opts} (`vim.lsp.ListOpts?`) See |vim.lsp.ListOpts|. -execute_command({command_params}) *vim.lsp.buf.execute_command()* - Executes an LSP server command. - - Parameters: ~ - • {command_params} (`lsp.ExecuteCommandParams`) - - See also: ~ - • https://microsoft.github.io/language-server-protocol/specifications/specification-current/#workspace_executeCommand - format({opts}) *vim.lsp.buf.format()* Formats a buffer using the attached (and optionally filtered) language server clients. |