fix: show all lsp of mulit-lsps workspace

navigator
DragonBillow 2 years ago committed by siduck
parent aabf8ca225
commit d66c000d48

@ -149,13 +149,18 @@ end
M.LSP_status = function()
local clients = vim.lsp.get_active_clients()
local name = false
local names = {}
for _, client in ipairs(clients) do
if client.attached_buffers[vim.api.nvim_get_current_buf()] then
name = client.name
break
table.insert(names, client.name)
end
end
local name = false
if names ~= {} then
name = table.concat(names, '/')
end
local content = name and "  LSP ~ " .. name .. " " or false
return content and ("%#St_LspStatus#" .. content) or ""
end

Loading…
Cancel
Save