CPProj is an extension for Visual Studio Code that helps you create and manage C++ projects based on CMake.
Motivation - DRY
I like programming in C++. I create lots of different projects to try different things. Recently, I found myself doing the same things over and over again, like writing the same CMakeLists.txt, linking the same libraries, executing the same commands. I don't like repeating myself. I built this extension to stop doing that.
Features
Fast project creation and setup
Simple and fast creation of basic C++ entities (Classes and their files)
Adding and managing dependencies (CPProj uses GitHub submodules and adds dependencies as sub-projects, which assures proper compilation)
Usage
Open a folder with VSCode where you want your project to be located.
Press F1, type in "CPProj" and press "Start new session".
Use the intiutive input fields to manipulate your project's settings.
Once you're satisfied with the settings, press "Create structure".
(In order to generate build files and compile the project I highly recommend using CMake Tools extension.)
Adding a submodule
Press "Add" in the submodules section.
Add the full url to the github page of a desired submodule.
Choose a name. Remember, the submodule will be cloned to [External folder]/[Submodule name]
Provide the local path to CMakeLists.txt of the submodule. If it's located in the root of the submodule (which is most likely the case), leave this field empty.
Provide the library (or target) name of this submodule. In order to do this, you should know the exact name of target generated by "add_library" command of this CMake project. Some examples: for glfw it's glfw, for glew it's glew or glew_s
Provide the local path to the include directory of the submodule.
Adding a new class
Right-click any folder in your project and press "Create class"
Choose a name for your class and hit Enter of press "Create"