# How to edit CMakePresets.json (nativeToolOptions not recognised)

**URL:** https://discourse.cmake.org/t/how-to-edit-cmakepresets-json-nativetooloptions-not-recognised/3424
**Category:** Usage
**Created:** [May 27, 2021, 3:46pm UTC](https://discourse.cmake.org/t/how-to-edit-cmakepresets-json-nativetooloptions-not-recognised/3424 "2021-05-27T15:46:46Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![DavidA](https://discourse.cmake.org/user_avatar/discourse.cmake.org/davida/32/128_2.png) [@DavidA](https://discourse.cmake.org/u/DavidA)
#### Post date: [May 27, 2021, 3:46pm UTC](https://discourse.cmake.org/t/how-to-edit-cmakepresets-json-nativetooloptions-not-recognised/3424/1 "2021-05-27T15:46:46Z")

</div>

I am new to CMake presets. I am experimenting with it in Visual Studio 2019 and Visual Studio Code.

I want to add ‘nativeToolOptions’ to a preset but the schema used by these tools seems to disallow it. Maybe I have misunderstood how to use it.

What is the best way to edit the json in a text editor and ensure that the correct schema is used?

I am using CMake 3.20.2 on Windows.

---

<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 27, 2021, 3:52pm UTC](https://discourse.cmake.org/t/how-to-edit-cmakepresets-json-nativetooloptions-not-recognised/3424/2 "2021-05-27T15:52:43Z")

</div>

`nativeToolOptions` is only available in build presets, not configure or test presets. It is present in the reference schema provided by CMake, though I can’t speak for what VS and VSCode are using.

---

<div class="post-metadata">

### Author: ![DavidA](https://discourse.cmake.org/user_avatar/discourse.cmake.org/davida/32/128_2.png) [@DavidA](https://discourse.cmake.org/u/DavidA)
#### Post date: [May 27, 2021, 3:55pm UTC](https://discourse.cmake.org/t/how-to-edit-cmakepresets-json-nativetooloptions-not-recognised/3424/3 "2021-05-27T15:55:17Z")

</div>

Thanks for your answer. I understand now.
