notskm / vscode-clang-tidy

MIT License
49 stars 25 forks source link

Support for compile_commands.json #74

Open jwatt opened 2 years ago

jwatt commented 2 years ago

The clangd extension supports specifying a compile_commands.json file which specifies the compiler arguments that are used to build each source file. The system that vscode-clang-tidy uses of requiring the user to specify a single set of arguments for the whole project doesn't work for projects where the arguments vary from file to file, or directory to directory at least. Could compile_commands.json support be added at some point? :-)

farnasirim commented 2 years ago

Seems like this is already supported: #40 I could verify using a full absolute path, couldn't get it to work with a path containing variables like ${workspaceFolder} or a relative path.