From cd9128982c2ba87d0052ccd49a1254e30980681d Mon Sep 17 00:00:00 2001 From: yuanyuyuan Date: Wed, 7 Aug 2024 12:46:31 +0800 Subject: [PATCH] fix: `init_options` is no longer supported in the rust-analyzer lsp config As lspconfig states in the doc, https://github.com/neovim/nvim-lspconfig/blob/master/doc/configs.md#rust_analyzer we need to pass the additional lspMux in the settings instead. This PR tries to fix the example config for neovim LSP. --- examples/neovim/init.lua | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/examples/neovim/init.lua b/examples/neovim/init.lua index 033e43b..47b9599 100644 --- a/examples/neovim/init.lua +++ b/examples/neovim/init.lua @@ -2,11 +2,13 @@ require'lspconfig'.rust_analyzer.setup { cmd = vim.lsp.rpc.connect("127.0.0.1", 27631), -- When using unix domain sockets, use something like: --cmd = vim.lsp.rpc.connect("/path/to/ra-multiplex.sock"), - init_options = { - lspMux = { - version = "1", - method = "connect", - server = "rust-analyzer", + settings = { + ["rust-analyzer"] = { + lspMux = { + version = "1", + method = "connect", + server = "rust-analyzer", + }, }, }, }