diff options
| author | Ruben Beltran del Rio <git@r.bdr.sh> | 2025-04-11 16:00:13 +0200 |
|---|---|---|
| committer | Ruben Beltran del Rio <git@r.bdr.sh> | 2025-04-11 16:00:13 +0200 |
| commit | 9748abe38cb64bfa388c3f5d441b3779f425cfdf (patch) | |
| tree | 58386f866bfbec3c8579e6d3324445f58eb6d01d /config/nvim/lua/lsp.lua | |
| parent | 7c36e04c36413c0469bc9f2a329ad362735a0ecf (diff) | |
| parent | 957e0f6119ab3681e02029cdd98d0a1bc3bbe092 (diff) | |
Merge branch 'main' of git.sr.ht:~rbdr/dotfiles
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({})) |