Fix LSP maybe

This commit is contained in:
Marcelo Jacobus 2025-01-22 14:41:22 -03:00
parent d5e0a7a0d1
commit e0e3965d75
2 changed files with 16 additions and 0 deletions

View file

@ -1,3 +1,9 @@
-- after/ftplugin/ruby.lua
local lspconfig = require("lspconfig")
lspconfig.ruby_lsp.setup({
cmd = { vim.fn.expand("~/.asdf/shims/ruby"), "-S", "ruby-lsp" },
})
local map = LazyVim.safe_keymap_set
-- map("n", "<leader>x", ":lua RunInTerminal('ruby ' .. vim.fn.expand('%'), true)<CR>", { buffer = true })

10
lua/plugins/lsp.lua Normal file
View file

@ -0,0 +1,10 @@
return {
"neovim/nvim-lspconfig",
opts = function(_, opts)
print("heeeey")
opts.servers = opts.servers or {}
opts.servers.ruby_lsp = vim.tbl_deep_extend("force", opts.servers.ruby_lsp or {}, {
cmd = { vim.fn.expand("~/.asdf/shims/ruby"), "-S", "ruby-lsp" },
})
end,
}