Skip to content

Commit 3c89a1d

Browse files
authored
Merge pull request #2 from stackb/readme-fixes
Update readme for vscode/settings.json
2 parents de929fe + a6fd3f5 commit 3c89a1d

1 file changed

Lines changed: 20 additions & 2 deletions

File tree

README.md

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,29 @@ conjunction with [bazel-stack-vscode](https://marketplace.visualstudio.com/items
99

1010
This extension provides a command `Bazel/C++: Generate Compilation Database`
1111
(`bsv.cc.compdb.generate`) that produces a file
12-
`${workspaceDIrectory}/compile_commmands.json`.
12+
`${workspaceDirectory}/compile_commmands.json` that assists with Intellisense
13+
for Bazel/C++ repositories.
1314

1415
To setup, edit your workspace settings (search for `bsv.cc.compdb.targets`) and
1516
configure a list of bazel labels for the `cc_binary` or `cc_library` targets
1617
you'd like to be indexed. The tool will then produce a command set for the
1718
transitive closure of those top-level targets.
1819

19-
Works best in conjuction with <https://marketplace.visualstudio.com/items?itemName=llvm-vs-code-extensions.vscode-clangd>.
20+
This can be added to your `.vscode/settings.json` and checked-in to VCS as
21+
follows:
22+
23+
```json
24+
{
25+
...
26+
"bsv.cc.compdb.targets": [
27+
"//app/foo:foo_binary",
28+
"//app/bar:bar_binary",
29+
"//app/baz:baz_binary",
30+
]
31+
}
32+
```
33+
34+
Works best in conjuction with
35+
<https://marketplace.visualstudio.com/items?itemName=llvm-vs-code-extensions.vscode-clangd>.
36+
37+
This feature was derived from <https://github.com/grailbio/bazel-compilation-database>.

0 commit comments

Comments
 (0)