CMake Builds with SublimeText and Atom
Mar 3, 2016
Both configurations will create a “build” folder for all the cmake
generated files.
- Create a project file or edit your existing one.
-
{ "project_name": "<PROJECT NAME>", "folders": [ { "path": "." } ], "build_systems": [ { "name": "cmake", "working_dir": "${project_path}", "shell_cmd": "mkdir build ; cd build && cmake .. && make -j8", "shell": true } ] }
- Use
Project -> Open Project
from now on instead of opening the folder.
CTRL + B
to build.
- Install the Atom Build package
- Create a new custom build file in the root of your project folder called
.atom-build.json
{ "cmd": "mkdir build ; cd build && cmake .. && make -j8", "name": "cmake", "sh": true, "cwd": "{PROJECT_PATH}" }
- Refresh the build.
- CTRL + P
- “Build: Refresh Targets”
F9
to build.