How to use CMake kits with a code-workspace #3943
-
Referring to the docs here I am able to define CMake kits for the user ( Some context: My
The Am I missing something simple? Any advice? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
I'll start with suggesting that if you migrate to CMakePresets.json, you'd be able to have more control over it because it is based on the presence of the file in the folder. For kits, to my knowledge, in the I think the only other possible option is to define various cmake settings in the code-workspace file to help with this (for example, you could set |
Beta Was this translation helpful? Give feedback.
I'll start with suggesting that if you migrate to CMakePresets.json, you'd be able to have more control over it because it is based on the presence of the file in the folder.
For kits, to my knowledge, in the
.code-workspace
file, you can specify which folders are opened when you open the workspace file. In that case, you should be able to use the folder.vscode/cmake-kits.json
. As for specifying a kit (or even a preset for that matter) for an entire workspace is not explicitly supported.I think the only other possible option is to define various cmake settings in the code-workspace file to help with this (for example, you could set
cmake.sourceDirectory
to the folders that are opened wi…