Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/salesforce/bazel-vscode-java
Bazel Java development extension for VS Code
https://github.com/salesforce/bazel-vscode-java
bazel java vscode-extension
Last synced: 28 days ago
JSON representation
Bazel Java development extension for VS Code
- Host: GitHub
- URL: https://github.com/salesforce/bazel-vscode-java
- Owner: salesforce
- License: bsd-3-clause
- Created: 2020-02-10T16:21:37.000Z (almost 5 years ago)
- Default Branch: main
- Last Pushed: 2024-07-29T22:10:37.000Z (5 months ago)
- Last Synced: 2024-07-31T07:15:51.540Z (5 months ago)
- Topics: bazel, java, vscode-extension
- Language: TypeScript
- Homepage:
- Size: 900 KB
- Stars: 39
- Watchers: 15
- Forks: 8
- Open Issues: 9
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
- Codeowners: CODEOWNERS
- Security: SECURITY.md
Awesome Lists containing this project
- awesome-bazel - VSCode Bazel Java extension - Proof-of-concept (POC) of a Bazel Java development extension for VS Code (Tooling / Editors)
README
# Bazel extension for Java™️ Language Support for VS Code
[![Build](https://github.com/salesforce/bazel-vscode-java/actions/workflows/ci.yml/badge.svg)](https://github.com/salesforce/bazel-vscode-java/actions/workflows/ci.yml)
[![License](https://img.shields.io/github/license/salesforce/bazel-vscode-java?style=for-the-badge)](https://github.com/salesforce/bazel-vscode-java/blob/master/LICENSE)This extension adds support for Bazel to the Java™️ Language Support for VS Code.
It plugs into the Eclipse Java Language server and computes project dependencies and classpath information using Bazel `BUILD` files.## Getting Started
Go and [install the extension](vscode:extension/sfdc.bazel-vscode-java) from the VSCode Marketplace (see [listing here](https://marketplace.visualstudio.com/items?itemName=sfdc.bazel-vscode-java)) or OpenVSX Registry (see [listing here](https://open-vsx.org/extension/sfdc/bazel-vscode-java)).
Once installed, open VSCode in any Bazel Workspace with Java targets.
The extension will look for a `WORKSPACE` (`WORKSPACE.bazel`) file to identify a Bazel workspace.
Next it will look for [a `.bazelproject` file](https://github.com/salesforce/bazel-eclipse/blob/main/docs/common/projectviews.md) to look for directories and targets to resolve.
If no `.bazelproject` file can be found a default one will be created.
For details of the lookup sequence please have a look at the latest implementation of [BazelProjectImporter.java in the language server](https://github.com/salesforce/bazel-eclipse/blob/0f526c8bd9cf970c4720240314b898218447ddc1/bundles/com.salesforce.bazel.eclipse.jdtls/src/main/java/com/salesforce/bazel/eclipse/jdtls/managers/BazelProjectImporter.java#L108).[Troubleshoot tips](docs/troubleshoot.md) may be useful if it doesn't "just work".