Skip to content

Commit bf8d8c5

Browse files
authored
Add multi-root workspace configuration file (#2505)
Currently, to make LSP servers like Ruby LSP properly work for gem, like `sentry-ruby`, we need to open `/sentry-ruby` separately. When working on tasks across multiple gems, like `sentry-ruby` and `sentry-rails`, it requires 2 separate VS Code windows while each can not interact with each other. For example, when using `Debug` code lens provided by Ruby LSP in `sentry-rails`'s tests, we can put breakpoints inside `sentry-rails`'s codebase, but not in `sentry-ruby`. But if we open the project through this new workspace configuration file, the multi-root workspace feature in VS Code will allow us to - Access code across multiple gems - Debug code with VS Code across multiple gems - Run language servers independently for each gem
1 parent ad535cc commit bf8d8c5

File tree

2 files changed

+35
-0
lines changed

2 files changed

+35
-0
lines changed

CONTRIBUTING.md

+5
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,11 @@ You can contribute to this project in the following ways:
1717

1818
And if you have any questions, please feel free to reach out on [Discord].
1919

20+
## Develop This Project With Multi-root Workspaces
21+
22+
If you use editors that support [VS Code-style multi-root workspaces](https://code.visualstudio.com/docs/editor/multi-root-workspaces),
23+
such as VS Code, Cursor...etc., opening the editor with `sentry-ruby.code-workspace` file will provide a better development experience.
24+
2025
## Contribute To Individual Gems
2126

2227
- Install the dependencies of a specific gem by running `bundle` in it's subdirectory. I.e:

sentry-ruby.code-workspace

+30
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
{
2+
"folders": [
3+
{
4+
"path": "sentry-ruby"
5+
},
6+
{
7+
"path": "sentry-rails"
8+
},
9+
{
10+
"path": "sentry-sidekiq"
11+
},
12+
{
13+
"path": "sentry-delayed_job"
14+
},
15+
{
16+
"path": "sentry-resque"
17+
},
18+
{
19+
"path": "sentry-opentelemetry"
20+
},
21+
{
22+
"path": ".github"
23+
}
24+
],
25+
"extensions": {
26+
"recommendations": [
27+
"Shopify.ruby-lsp"
28+
]
29+
}
30+
}

0 commit comments

Comments
 (0)