# nvim-lspconfig ## Install ```vim Plug 'neovim/nvim-lspconfig' lua << EOF require'lspconfig'.rust_analyzer.setup{} EOF ``` ```bash ``` Commands and default values: ```text Commands: - CargoReload: Reload current cargo workspace Default Values: cmd = { "rust-analyzer" } filetypes = { "rust" } root_dir = root_pattern("Cargo.toml", "rust-project.json") settings = { ["rust-analyzer"] = {} } ``` ## Configuration ### Install [[rust-analyzer]] ![[rust-analyzer#Install]] ### Config I just used their default minimal config: ```vim " Default minimal config lua require'lspconfig'.rust_analyzer.setup{} ``` [[rust-analyzer]] docs: https://rust-analyzer.github.io/manual.html#nvim-lsp - See https://sharksforarms.dev/posts/neovim-rust/ for more tips on getting started. - Check out https://github.com/simrat39/rust-tools.nvim for a batteries included rust-analyzer setup for neovim.