Bazel Support
還沒有人認領這個 Issue。
評估
- 難度
- 5/5
- 預估耗時
- 一週以上
- 新手友好度
- 12/100
- Issue 類型
- 功能
- 描述清晰度
- 需要釐清
- 活躍度
- 停滯
研究方向
Start with the linked salesforce/bazel-vscode-java and redhat-developer/vscode-java references to see how the bundles list reaches jdtls through initializationOptions. The open question is whether the Zed extension API can download, extract and locate these jars, which is unresolved in the thread. Done would be either a verified manual setup that loads the Bazel bundles, or a settled answer that the API cannot do this.
由索引模型根據 Issue 內容生成。
描述
I think it would be possible to support bazel with jdtls, just as salesforce/bazel-vscode-java provides jars via contributes.javaExtensions to redhat-developer/vscode-java which get injected into the jdtls initializationOptions.bundles
The salesforce/bazel-vscode-java extension downloads p2-repository.zip which it then extracts, does some renaming and puts them under ~/.vscode/extensions/sfdc.bazel-vscode-java-1.4.0/server. And since salesforce/bazel-vscode-java exports a list of those jars via contributes.javaExtensions in it's package.json those settings are available to other extensions.
Source: salesforce/bazel-vscode-java:gulpfile.js and salesforce/bazel-vscode-java:package.json
When redhat-developer/vscode-java starts the language server it pulls from contributes.javaExtensions and provides those as a bundles array under the initializationOptions when starting jdtls:
Source: redhat-developer/vscode-java:src/extension.ts
I think the Zed Java Extension could potentially add support for Bazel with the following settings:
{
"lsp": {
"jdtls": {
"initialization_options": {
"bundles": [
"somepath/org.eclipse.equinox.event.jar",
"somepath/com.github.ben-manes.caffeine.jar",
"somepath/org.jsr-305.jar",
"somepath/org.fusesource.jansi.jar",
"somepath/com.google.protobuf.jar",
"somepath/com.salesforce.bazel.importedsource.jar",
"somepath/com.salesforce.bazel.sdk.jar",
"somepath/com.salesforce.bazel.eclipse.core.jar",
"somepath/com.salesforce.bazel.eclipse.jdtls.jar"
]
}
}
}
}
Totally untested but I wanted to document my research somewhere.
Not sure whether the current Extension APIs are sufficient to support downloading arbitrary zip files, extracting a subset of them and then injecting the correct pathing for where those files are. But assuming this works, we could certainly provide instructions doing this manually.
I'm not a Java programmer.
I have no experience with Bazel.
Would love if someone can see if they can get this working.
See also:
- 主要語言
- Rust
- 星號
- 225
- 分支
- 47
- 平均合併
- 3 小時
- 30 天內合併 PR
- 5
環境準備
這個專案沒有提供開發容器、Dockerfile 或貢獻指南,環境需要你自己搭建:先看它的 README,通用步驟見我們的新手貢獻指南。
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
zed-extensions/java 的其他 Issue
-
難度 1/5 1 小時以內 新手友好度 88/100
zed-extensions/java#325 · 1 則留言 ·
-
難度 2/5 1-3 小時 新手友好度 62/100
zed-extensions/java#133 · 1 則留言 ·
-
難度 3/5 1-2 天 新手友好度 45/100
zed-extensions/java#324 · 1 則留言 ·
-
難度 4/5 3-5 天 新手友好度 30/100
zed-extensions/java#272 · 6 則留言 ·
-
language-server
難度 4/5 3-5 天 新手友好度 25/100
zed-extensions/java#246 · 4 則留言 ·
查看 zed-extensions/java 的全部 Issue
相似的 Issue
-
bug cluster redis-compat
難度 2/5 1-3 小時 新手友好度 78/100
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 77/100
tangency-labs/solidcore#2839 ·
維護者通常 1 天內回覆
-
bug priority: low ui
難度 2/5 1-3 小時 新手友好度 68/100
storytold/gridcraft#3446 · 1 則留言 ·
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 88/100
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 84/100
madeofpendletonwool/PinePods#1078 ·
維護者通常 1 天內回覆