Create build directory only if build is performed
See original GitHub issueBrief Issue Summary
The build
directory should NOT be (re)created every time user opens a folder with CMakeLists.txt
in VSCode, but only on-demand when actual build is configured/performed.
Expected:
mkdir test
- Create
test/CMakeListst.txt
cmake_minimum_required(VERSION 3.10 FATAL_ERROR)
project(test)
- Explore® to parent of
test
> right-click ontest
> Open with Code - Close the Code
- No
test/build
subdirectory should be created and left dangling as empty cruft!
Apparent Behavior:
test/build
subdirectory is created, despite it is EMPTY and has NOT been used.
[[For issues, fill out the following. Otherwise delete this section.]]
- Operating System: Windows 10 Version 1709 (Build 16299)
- CMake Version: 3.11
- VSCode Version: 1.22.1
- CMake Tools Extension Version: 0.10.4
Issue Analytics
- State:
- Created 5 years ago
- Comments:5 (5 by maintainers)
Top Results From Across the Web
Automatically Making Build Directories in Make
Here you can see mkdir is only run once and touching the build directory doesn't force a rebuild of the targets. Is this...
Read more >Create directories using make file - Stack Overflow
You should create files and if a file creation needs a new directory then ... Default goal all: gccversion makedir build finalize list...
Read more >Automatically create and configure build directory if it doesn't ...
I recently had to build a meson project and their way of configuring a project by just running meson build is very convenient....
Read more >Customize your build - MSBuild - Microsoft Learn
Create a new file in the root of your repo called Directory.Build.props. Add the following XML to the file. XML Copy.
Read more >Making directories in GNU Make | CMCrossroads
A related solution is to only build the directory when all is being built. This means that the directories won\'t get created every...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@vector-of-bool using the latest VSCode 1.25.0-insider with the CMake Tools 1.0.1 I no longer see the problem occurring. Thank you!
I’m going to close this, but re-open it if it is still occurring.