aboutsummaryrefslogtreecommitdiffstats
path: root/lua/alpha/lsp/servers.lua
diff options
context:
space:
mode:
authorAriel D'Alessandro <dalessandro.ariel@gmail.com>2023-09-03 12:09:14 +0200
committerAriel D'Alessandro <dalessandro.ariel@gmail.com>2023-09-03 12:09:14 +0200
commit26f078de81ee51f1fb91a5d4f5dc7837515ab8c0 (patch)
tree2fb6aeb92245ca34b111d2536e7a2c4940a06716 /lua/alpha/lsp/servers.lua
parent9531ae2ef6c02640d2daa2608dd9665c1643a225 (diff)
downloadnvim-conf-26f078de81ee51f1fb91a5d4f5dc7837515ab8c0.tar.gz
nvim-conf-26f078de81ee51f1fb91a5d4f5dc7837515ab8c0.zip
more updates
Diffstat (limited to 'lua/alpha/lsp/servers.lua')
-rw-r--r--lua/alpha/lsp/servers.lua22
1 files changed, 17 insertions, 5 deletions
diff --git a/lua/alpha/lsp/servers.lua b/lua/alpha/lsp/servers.lua
index d2233a1..ab70468 100644
--- a/lua/alpha/lsp/servers.lua
+++ b/lua/alpha/lsp/servers.lua
@@ -28,23 +28,23 @@ return {
flags = lsp_flags,
}
end,
- ["html"] = function ()
+ ["html"] = function()
local config = {
on_attach = lsp_attach,
flags = lsp_flags,
}
- if vim.fn.executable("html-languageserver") == 1 then
+ if vim.fn.executable "html-languageserver" == 1 then
config.cmd = { "html-languageserver", "--stdio" }
end
return config
end,
- ["jsonls"] = function ()
+ ["jsonls"] = function()
local config = {
on_attach = lsp_attach,
flags = lsp_flags,
}
- if vim.fn.executable("json-languageserver") == 1 then
+ if vim.fn.executable "json-languageserver" == 1 then
config.cmd = { "json-languageserver", "--stdio" }
end
@@ -85,8 +85,20 @@ return {
filetypes = { "php", "cucumber" },
init_options = {
["language_server_worse_reflection.inlay_hints.enable"] = true,
+ ["language_server_worse_reflection.inlay_hints.params"] = true,
-- ["language_server_worse_reflection.inlay_hints.types"] = true,
- -- ["language_server_worse_reflection.inlay_hints.params"] = true,
+ ["language_server_configuration.auto_config"] = false,
+ ["code_transform.import_globals"] = true,
+ ["language_server_phpstan.enabled"] = true,
+ ["language_server_phpstan.bin"] = "phpstan",
+ },
+ handlers = {
+ ["textDocument/inlayHint"] = function(err, result, ...)
+ for _, res in ipairs(result) do
+ res.label = res.label .. ": "
+ end
+ vim.lsp.handlers["textDocument/inlayHint"](err, result, ...)
+ end,
},
}
end,