docs: Document how to use project-specific settings for Ruby LSP (#27310)
I think it's helpful to illustrate how some settings can be added to the project settings file rather than being global. Release Notes: - N/A --------- Co-authored-by: Peter Tripp <peter@zed.dev>
This commit is contained in:
parent
8294b9f674
commit
f19e1e3b5f
1 changed files with 15 additions and 0 deletions
|
@ -158,6 +158,21 @@ Ruby LSP uses pull-based diagnostics which Zed doesn't support yet. We can tell
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
LSP `settings` and `initialization_options` can also be project-specific. For example to use [standardrb/standard](https://github.com/standardrb/standard) as a formatter and linter for a particular project, add this to a `.zed/settings.json` inside your project repo:
|
||||||
|
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"lsp": {
|
||||||
|
"ruby-lsp": {
|
||||||
|
"initialization_options": {
|
||||||
|
"formatter": "standard",
|
||||||
|
"linters": ["standard"]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
By default, Ruby LSP does not use `bundle exec` to run in the context of the bundle. To enable that, you can use the `use_bundler` configuration option:
|
By default, Ruby LSP does not use `bundle exec` to run in the context of the bundle. To enable that, you can use the `use_bundler` configuration option:
|
||||||
|
|
||||||
```json
|
```json
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue