File tree Expand file tree Collapse file tree 1 file changed +37
-0
lines changed Expand file tree Collapse file tree 1 file changed +37
-0
lines changed Original file line number Diff line number Diff line change @@ -192,6 +192,43 @@ folder is used.
192
192
193
193
See [ this issue] [ mason-abi ] for further information.
194
194
195
+ ### Built-In vim.lsp
196
+
197
+ { .note }
198
+ Ensure that you are using NeoVim 0.11 or newer.
199
+
200
+ You can also configure the Ruby LSP without the nvim-lspconfig plugin.
201
+ Create an ` lsp ` directory inside your config directory and create a file ` ruby-lsp.lua ` inside it
202
+ with the following content:
203
+
204
+ ``` lua
205
+ -- on Linux and macOS the default location is ~/.config/nvim/lsp/ruby-lsp.lua
206
+ return {
207
+
208
+ filetypes = { " ruby" },
209
+
210
+ cmd = { " ruby-lsp" } -- or { "bundle", "exec", "ruby-lsp" },
211
+
212
+ root_markers = { " Gemfile" , " .git" },
213
+
214
+ init_options = {
215
+ formatter = ' standard' ,
216
+ linters = { ' standard' },
217
+ addonSettings = {
218
+ [" Ruby LSP Rails" ] = {
219
+ enablePendingMigrationsPrompt = false ,
220
+ },
221
+ },
222
+ },
223
+ }
224
+ ```
225
+
226
+ Then you need to enable it, e.g., inside ` init.lua ` :
227
+
228
+ ``` lua
229
+ vim .lsp .enable (" ruby-lsp" )
230
+ ```
231
+
195
232
### Additional setup (optional)
196
233
197
234
` rubyLsp/workspace/dependencies ` is a custom method currently supported only in the VS Code plugin.
You can’t perform that action at this time.
0 commit comments