mirror of
https://github.com/LunarVim/LunarVim.git
synced 2025-07-19 18:25:22 +02:00
Check lsp client is active for all language files (#790)
This commit is contained in:
parent
9233611bdc
commit
53fed9d655
33 changed files with 412 additions and 291 deletions
|
@ -8,6 +8,16 @@ function lv_utils.reload_lv_config()
|
|||
vim.cmd ":PackerInstall"
|
||||
end
|
||||
|
||||
function lv_utils.check_lsp_client_active(name)
|
||||
local clients = vim.lsp.get_active_clients()
|
||||
for _, client in pairs(clients) do
|
||||
if client.name == name then
|
||||
return true
|
||||
end
|
||||
end
|
||||
return false
|
||||
end
|
||||
|
||||
function lv_utils.define_augroups(definitions) -- {{{1
|
||||
-- Create autocommand groups based on the passed definitions
|
||||
--
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue