feat(nvim): run clippy using rust-analyzer

nixos
Moritz Böhme 2023-07-29 17:06:58 +02:00
parent 916674d5b2
commit 4cd51917fc
Signed by: moritz
GPG Key ID: 970C6E89EB0547A9
1 changed files with 10 additions and 1 deletions

View File

@ -122,7 +122,6 @@ local servers = {
"nil_ls", "nil_ls",
"pylsp", "pylsp",
"ruff_lsp", "ruff_lsp",
"rust_analyzer",
"typst_lsp", "typst_lsp",
"gopls", "gopls",
} }
@ -130,6 +129,16 @@ for _, lsp in ipairs(servers) do
lspconfig_setup(lsp, {}) lspconfig_setup(lsp, {})
end end
lspconfig_setup("rust_analyzer", {
settings = {
["rust-analyzer"] = {
checkOnSave = {
command = "clippy",
},
},
},
})
lspconfig_setup("lua_ls", { lspconfig_setup("lua_ls", {
settings = { settings = {
Lua = { Lua = {