# can build presets run a configuration?

**URL:** https://discourse.cmake.org/t/can-build-presets-run-a-configuration/3428
**Category:** Usage
**Created:** [May 28, 2021, 8:02am UTC](https://discourse.cmake.org/t/can-build-presets-run-a-configuration/3428 "2021-05-28T08:02:34Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![hex](https://discourse.cmake.org/user_avatar/discourse.cmake.org/hex/32/363_2.png) [@hex](https://discourse.cmake.org/u/hex)
#### Post date: [May 28, 2021, 8:02am UTC](https://discourse.cmake.org/t/can-build-presets-run-a-configuration/3428/1 "2021-05-28T08:02:34Z")

</div>

The build preset inherits a configure preset. When building a project from the command line like this

```auto
cmake --build --preset default

```

can CMake run the configure command for me? Currently it results in `Error: /tmp/test/build is not a directory`.

This does not mean i don’t want to ever manually run a configure step (which i still can do), but CMake build already depends on a configuration.

---

<div class="post-metadata">

### Author: ![kyle.edwards](https://discourse.cmake.org/letter_avatar_proxy/v4/letter/k/65b543/32.png) [@kyle.edwards](https://discourse.cmake.org/u/kyle.edwards)
#### Post date: [May 28, 2021, 12:12pm UTC](https://discourse.cmake.org/t/can-build-presets-run-a-configuration/3428/2 "2021-05-28T12:12:45Z")

</div>

Yes, `CMakePresets.json` supports configure presets, in the `configurePresets` field. You can then run it with:

```auto
cmake --preset configureDefault ..

```
