From 4cd5c4162ab398cfe5c7c8ef9a9480280aa0b0ce Mon Sep 17 00:00:00 2001 From: Kevin Robayna Date: Mon, 17 Jun 2024 09:37:34 +0100 Subject: [PATCH] feat(extras): improve ruby extra by using RubyLsp Shopify started working on its own LSP (https://github.com/Shopify/ruby-lsp) and it performs way better than Solargraph which has a lot of limitations. This paired with sorbet gives better IntelliSense when navigating the code. One caveat though is that RubyLsp does not work very well with NeoVim < 0.10 https://github.com/Shopify/ruby-lsp/blob/main/EDITORS.md#neovim --- lua/lazyvim/plugins/extras/lang/ruby.lua | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/lua/lazyvim/plugins/extras/lang/ruby.lua b/lua/lazyvim/plugins/extras/lang/ruby.lua index c70e645d..c8464099 100644 --- a/lua/lazyvim/plugins/extras/lang/ruby.lua +++ b/lua/lazyvim/plugins/extras/lang/ruby.lua @@ -11,9 +11,16 @@ return { }, { "neovim/nvim-lspconfig", + ---@class PluginLspOpts opts = { + ---@type lspconfig.options servers = { - solargraph = {}, + -- disable solargraph from auto running when you open ruby files + solargraph = { + autostart = false, + }, + -- ruby_lsp will be automatically installed with mason and loaded with lspconfig + ruby_lsp = {}, }, }, },