aboutsummaryrefslogtreecommitdiffstats
path: root/lua
diff options
context:
space:
mode:
authorGuilherme Soares <48023091+guilhas07@users.noreply.github.com>2024-12-14 01:06:28 +0100
committerGitHub <noreply@github.com>2024-12-13 16:06:28 -0800
commit3cb6c05779459eb5fe9cddbb47675593594f0415 (patch)
tree2fd0dadfc8222bdc8db02e082bcc6e698bfc067d /lua
parentfix(regression): fix for vim.fs.find regression not returning parent director... (diff)
downloadnvim-lspconfig-3cb6c05779459eb5fe9cddbb47675593594f0415.tar
nvim-lspconfig-3cb6c05779459eb5fe9cddbb47675593594f0415.tar.gz
nvim-lspconfig-3cb6c05779459eb5fe9cddbb47675593594f0415.tar.bz2
nvim-lspconfig-3cb6c05779459eb5fe9cddbb47675593594f0415.tar.lz
nvim-lspconfig-3cb6c05779459eb5fe9cddbb47675593594f0415.tar.xz
nvim-lspconfig-3cb6c05779459eb5fe9cddbb47675593594f0415.tar.zst
nvim-lspconfig-3cb6c05779459eb5fe9cddbb47675593594f0415.zip
docs: how to get package.json parent dir #3506
Diffstat (limited to 'lua')
-rw-r--r--lua/lspconfig/util.lua6
1 files changed, 3 insertions, 3 deletions
diff --git a/lua/lspconfig/util.lua b/lua/lspconfig/util.lua
index cc97867f..4bd82b5b 100644
--- a/lua/lspconfig/util.lua
+++ b/lua/lspconfig/util.lua
@@ -378,17 +378,17 @@ function M.path.exists(filename)
return stat and stat.type or false
end
---- @deprecated use `vim.fs.find('.hg', { path = startpath, upward = true })[1]` instead
+--- @deprecated use `vim.fs.dirname(vim.fs.find('.hg', { path = startpath, upward = true })[1])` instead
function M.find_mercurial_ancestor(startpath)
return vim.fs.dirname(vim.fs.find('.hg', { path = startpath, upward = true })[1])
end
---- @deprecated use `vim.fs.find('node_modules', { path = startpath, upward = true })[1]` instead
+--- @deprecated use `vim.fs.dirname(vim.fs.find('node_modules', { path = startpath, upward = true })[1])` instead
function M.find_node_modules_ancestor(startpath)
return vim.fs.dirname(vim.fs.find('node_modules', { path = startpath, upward = true })[1])
end
---- @deprecated use `vim.fs.find('package.json', { path = startpath, upward = true })[1]` instead
+--- @deprecated use `vim.fs.dirname(vim.fs.find('package.json', { path = startpath, upward = true })[1])` instead
function M.find_package_json_ancestor(startpath)
return vim.fs.dirname(vim.fs.find('package.json', { path = startpath, upward = true })[1])
end