Commit 7b83f21 1 parent 47f53be commit 7b83f21 Copy full SHA for 7b83f21
File tree 1 file changed +16
-0
lines changed
1 file changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -72,6 +72,22 @@ When you run `eglot` command it will run `ruby-lsp` process for you.
72
72
The [ nvim-lspconfig] ( https://github.com/neovim/nvim-lspconfig/blob/master/lua/lspconfig/server_configurations/ruby_lsp.lua )
73
73
plugin has support for Ruby LSP.
74
74
75
+ The Ruby LSP can be configured using the ` init_options ` key when setting up the LSP.
76
+
77
+ A great example of this configuration style is enabling the Standard add-on for
78
+ the Ruby LSP to enable formatting and pull-style diagnostics. The following snippet
79
+ enables ` standard ` for both formatting and pull-diagnostic linting.
80
+
81
+ ``` lua
82
+ local lspconfig = require (' lspconfig' )
83
+ lspconfig .ruby_lsp .setup ({
84
+ init_options = {
85
+ formatter = ' standard' ,
86
+ linters = { ' standard' },
87
+ },
88
+ })
89
+ ```
90
+
75
91
### Mason
76
92
77
93
You can use [ mason.nvim] ( https://github.com/williamboman/mason.nvim ) ,
You can’t perform that action at this time.
0 commit comments