mirror of
https://github.com/NotAShelf/nvf.git
synced 2026-02-23 20:12:00 +00:00
Merge pull request #1404 from Kazimazi/fix-deprecation-warning
Some checks are pending
Set up binary cache / cachix (default) (push) Waiting to run
Set up binary cache / cachix (maximal) (push) Waiting to run
Set up binary cache / cachix (nix) (push) Waiting to run
Treewide Checks / Validate flake (push) Waiting to run
Treewide Checks / Check formatting (push) Waiting to run
Treewide Checks / Check source tree for typos (push) Waiting to run
Treewide Checks / Validate documentation builds (push) Waiting to run
Treewide Checks / Validate documentation builds-1 (push) Waiting to run
Treewide Checks / Validate documentation builds-2 (push) Waiting to run
Treewide Checks / Validate documentation builds-3 (push) Waiting to run
Treewide Checks / Validate hyperlinks in documentation sources (push) Waiting to run
Treewide Checks / Validate Editorconfig conformance (push) Waiting to run
Build and deploy documentation / Check latest commit (push) Waiting to run
Build and deploy documentation / publish (push) Blocked by required conditions
Some checks are pending
Set up binary cache / cachix (default) (push) Waiting to run
Set up binary cache / cachix (maximal) (push) Waiting to run
Set up binary cache / cachix (nix) (push) Waiting to run
Treewide Checks / Validate flake (push) Waiting to run
Treewide Checks / Check formatting (push) Waiting to run
Treewide Checks / Check source tree for typos (push) Waiting to run
Treewide Checks / Validate documentation builds (push) Waiting to run
Treewide Checks / Validate documentation builds-1 (push) Waiting to run
Treewide Checks / Validate documentation builds-2 (push) Waiting to run
Treewide Checks / Validate documentation builds-3 (push) Waiting to run
Treewide Checks / Validate hyperlinks in documentation sources (push) Waiting to run
Treewide Checks / Validate Editorconfig conformance (push) Waiting to run
Build and deploy documentation / Check latest commit (push) Waiting to run
Build and deploy documentation / publish (push) Blocked by required conditions
lsp: fix client.supports_method deprecation warning in neovim 0.12
This commit is contained in:
commit
df94a99201
3 changed files with 3 additions and 2 deletions
|
|
@ -202,6 +202,7 @@ https://github.com/gorbit99/codewindow.nvim
|
||||||
|
|
||||||
- Added [`grug-far.nvim`](https://github.com/MagicDuck/grug-far.nvim) the find
|
- Added [`grug-far.nvim`](https://github.com/MagicDuck/grug-far.nvim) the find
|
||||||
and replace tool for neovim.
|
and replace tool for neovim.
|
||||||
|
- Fix lsp `client.supports_method` deprecation warning in nvim v0.12.
|
||||||
|
|
||||||
[Ladas552](https://github.com/Ladas552)
|
[Ladas552](https://github.com/Ladas552)
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -97,7 +97,7 @@
|
||||||
local function symbol_info()
|
local function symbol_info()
|
||||||
local bufnr = vim.api.nvim_get_current_buf()
|
local bufnr = vim.api.nvim_get_current_buf()
|
||||||
local clangd_client = vim.lsp.get_clients({ bufnr = bufnr, name = "clangd" })[1]
|
local clangd_client = vim.lsp.get_clients({ bufnr = bufnr, name = "clangd" })[1]
|
||||||
if not clangd_client or not clangd_client.supports_method 'textDocument/symbolInfo' then
|
if not clangd_client or not clangd_client:supports_method 'textDocument/symbolInfo' then
|
||||||
return vim.notify('Clangd client not found', vim.log.levels.ERROR)
|
return vim.notify('Clangd client not found', vim.log.levels.ERROR)
|
||||||
end
|
end
|
||||||
local win = vim.api.nvim_get_current_win()
|
local win = vim.api.nvim_get_current_win()
|
||||||
|
|
|
||||||
|
|
@ -48,7 +48,7 @@ in {
|
||||||
default_on_attach(client, bufnr)
|
default_on_attach(client, bufnr)
|
||||||
|
|
||||||
${optionalString cfg.inlayHints.enable ''
|
${optionalString cfg.inlayHints.enable ''
|
||||||
if client and client.supports_method(vim.lsp.protocol.Methods.textDocument_inlayHint) then
|
if client and client:supports_method(vim.lsp.protocol.Methods.textDocument_inlayHint) then
|
||||||
vim.lsp.inlay_hint.enable(not vim.lsp.inlay_hint.is_enabled({ bufnr = bufnr }), { bufnr = bufnr })
|
vim.lsp.inlay_hint.enable(not vim.lsp.inlay_hint.is_enabled({ bufnr = bufnr }), { bufnr = bufnr })
|
||||||
end
|
end
|
||||||
''}
|
''}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue