Most users start with configurePresets and buildPresets .
cmake --preset dev-linux-gcc
"name": "dev-test", "displayName": "Run Unit Tests", "configurePreset": "dev-default", "configuration": "Debug", "output": "outputOnFailure": true , "execution": "noTestsAction": "error", "stopOnFailure": true cmakepresets.json example
For CI/CD pipelines (e.g., GitHub Actions, GitLab CI), CMakePresets.json is invaluable. The pipeline script becomes simplified and declarative: Most users start with configurePresets and buildPresets
"name": "debug-base", "hidden": true, "cacheVariables": "CMAKE_BUILD_TYPE": "Debug" "displayName": "Run Unit Tests"
,
The CMakePresets.json file represents a significant maturation of the CMake ecosystem. By formalizing the definition of configure, build, and test parameters, it reduces the cognitive load on developers and ensures parity between local development environments and automated pipelines.