Bazel Build EAR
What is this?
bbear
creates a compile_commands.json
file in the workspace root of a
Bazel project to use with clangd.
At the core, it's an alternative frontend for
bazel-compilation-database written in Go that fixes a few issues
that bothered me but were painful to deal with in Bash. Please see that
repository for more information.
See also: bear
Installation
Install bbear
like any other go binary:
go install bbear.go
or
go install github.com/phoebe-bell/bbear@latest
Usage
For most use-cases, it should be as simple as running bbear
in your project's
workspace root.
cd your_project
bbear
Alternatively, you can pass in a custom query command to select for targets:
bbear -query //foo/bar:all
As usual, see bbear -help
for the complete list of options.
bbear
has only been tested on Linux. It may take some extra work for it to
work on other platforms.