summaryrefslogtreecommitdiff
path: root/lua/lang/ruby.lua
diff options
context:
space:
mode:
authorichigo-gyuunyuu <[email protected]>2021-07-21 01:03:15 +0530
committerGitHub <[email protected]>2021-07-21 00:03:15 +0430
commit0064b446a02be13dba0f16f084e073b347716710 (patch)
tree203f9907132b86c37733096bd139cf224b4dd1ad /lua/lang/ruby.lua
parent9e640fa4d99beeec97292a00a51b335960aa2b0f (diff)
[Feature] Allow for custom path to a language server binary (#1043)
Diffstat (limited to 'lua/lang/ruby.lua')
-rw-r--r--lua/lang/ruby.lua5
1 files changed, 4 insertions, 1 deletions
diff --git a/lua/lang/ruby.lua b/lua/lang/ruby.lua
index 8b3b1a76..1975acfd 100644
--- a/lua/lang/ruby.lua
+++ b/lua/lang/ruby.lua
@@ -14,6 +14,9 @@ M.config = function()
stdin = true,
},
linters = { "ruby" },
+ lsp = {
+ path = DATA_PATH .. "/lspinstall/ruby/solargraph/solargraph",
+ },
}
end
@@ -48,7 +51,7 @@ M.lsp = function()
if not require("lv-utils").check_lsp_client_active "solargraph" then
-- If you are using rvm, make sure to change below configuration
require("lspconfig").solargraph.setup {
- cmd = { DATA_PATH .. "/lspinstall/ruby/solargraph/solargraph", "stdio" },
+ cmd = { O.lang.ruby.lsp.path, "stdio" },
on_attach = require("lsp").common_on_attach,
handlers = {
["textDocument/publishDiagnostics"] = vim.lsp.with(vim.lsp.diagnostic.on_publish_diagnostics, {