bazel
Installation
SKILL.md
Bazel Monorepos
Make build changes against the actual target graph and pinned Bazel/ruleset versions. Examples cover Bazel 9.2.0; they are not an upgrade instruction. The user's explicit instructions take precedence over this skill's guidelines.
Establish the relevant context
Use the affected targets, error output, or requested build outcome as input. Check .bazelversion, relevant module declarations, BUILD files, and the configuration involved in the task. Read other repository configuration only when it affects that question.
| Question | Tool |
|---|---|
| Target dependencies, reverse dependencies, paths | bazel query |
Selected flags, platforms, toolchains, or select() branches |
bazel cquery with the failing invocation's configuration |
| Actual commands, inputs, outputs, tools | bazel aquery |
| External modules, versions, generated repositories | bazel mod |
| Cache misses or execution performance | Execution logs, profiles, BEP |
If the failing target or invocation cannot be inferred, ask for it and continue independent inspection. Do not invent repository pins or remote-cache endpoints.