diff options
| author | Ruben Beltran del Rio <git@r.bdr.sh> | 2025-04-11 15:43:10 +0200 |
|---|---|---|
| committer | Ruben Beltran del Rio <git@r.bdr.sh> | 2025-04-11 15:43:10 +0200 |
| commit | d0dd2c9e2540e1fe29f673d32aff27e4591d5297 (patch) | |
| tree | 6848f852e4a5dc35e6567213637be19cd0ef291b /config/nvim/lua/lsp.lua | |
| parent | d5c593a20dd18bbb0fe77389882693a79c779d83 (diff) | |
LSP and plugin improvements
Diffstat (limited to 'config/nvim/lua/lsp.lua')
| -rw-r--r-- | config/nvim/lua/lsp.lua | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/config/nvim/lua/lsp.lua b/config/nvim/lua/lsp.lua index e74a330..7dfb050 100644 --- a/config/nvim/lua/lsp.lua +++ b/config/nvim/lua/lsp.lua @@ -11,8 +11,29 @@ lspconfig.dartls.setup(coq.lsp_ensure_capabilities({})) lspconfig.rust_analyzer.setup(coq.lsp_ensure_capabilities({ -- Server-specific settings. See `:help lspconfig-setup` settings = { - ['rust-analyzer'] = {}, + ['rust-analyzer'] = { + imports = { + granularity = { + group = "module", + }, + prefix = "self", + }, + cargo = { + buildScripts = { + enable = true, + }, + }, + procMacro = { + enable = true + }, + checkOnSave = { + command = "clippy" + } + }, }, + on_attach = function(client, bufnr) + vim.lsp.inlay_hint.enable(true, { bufnr = bufnr }) + end })) lspconfig.lua_ls.setup(coq.lsp_ensure_capabilities({})) |