Skip to content

cdump/bazel_compile_commands

Repository files navigation

bazel-compile-commands

Generates compile_commands.json for your bazel project

What is compile_commands.json

It's a file used by code completion tools, like clangd

Look at example.cpp in vim with coc-nvim plugin with/without that database:

vim with/without compile_commands.json

How to use

See example

With --experimental_action_listener we generate JSON files for every build piece and with gen_compile_commands.sh we make final compile_commands.json

Acknowledgements