Bazel Support for Visual Studio Code.
![]() |
||
| Bazel | Stack | VSCode |
https://stackb.github.io/bazel-stack-vscode/
https://marketplace.visualstudio.com/items?itemName=StackBuild.bazel-stack-vscode
-
bazelandstarlarkfiles (BUILD,.bazel,WORKSPACE,*.bzl,.star,*.sky):- syntax highlighting
- formatting & linting diagnostics (via
buildifier) - hover to get links to bazel documentation
- hover to get bazel rule & starlark function reference (via Starlark Language Server)
- go to definition for bazel labels
-
bazelrcfiles (*.bazelrc):- syntax highlighting
- hover to get flag reference & links to bazel docs / bazel codesearch
- completion for all 834 available flags by command (includes undocumented flags).
-
launch.bazelrcfile (a file where you can stash frequently executed commands):- syntax highlighting
- hover over command name to get a "codelens" (click to run the command)
- repeat previous command for iterative development (
shift+ctrl+space) - custom problem matcher for rules_go output
Includes all 834 flags (including undocumented options)
Use the
' '(space) or'='(equals) to commit choice and continue typing
The advanced features are available with a Bzl subscription. Sign-up on the website or within the vscode extension. Read more about advanced features on the documentation site.
Github Rate Limits: This extension makes requests to the github v3 API. If
you experience errors due to rate limits, export GITHUB_TOKEN={MY_PERSONAL_TOKEN} and relaunch vscode to get higher rate
limits.
NOTE: portions of this extension were adapted from https://github.com/bazelbuild/vscode-bazel (Apache 2.0).







