Only enable rust_analyer if it is installed

This commit is contained in:
Dreaded_X 2025-06-03 21:56:19 +02:00
parent da7c214afe
commit 0458cb0825
Signed by: Dreaded_X
GPG Key ID: 5A0CBFE3C3377FAA

View File

@ -148,5 +148,7 @@ vim.api.nvim_create_autocmd("LspAttach", {
end,
})
-- Manually enable rust analyzer
vim.lsp.enable("rust_analyzer")
-- Manually enable rust analyzer, if installed
if vim.fn.executable("rust_analyzer") then
vim.lsp.enable("rust_analyzer")
end