
$VIEW_ROOT is main project open for CLion or. Project/solution root-wise structure (as seen in project toolbox views in IDEs) Main CMakeList.txt: $REPO_ROOT/CmakeList.txtĮxample subprojects: $REPO_ROOT/foo_slib/ $REPO_ROOT/program/Įxample Source files: $REPO_ROOT/program/main.cpp $REPO_ROOT/program/gui_init.h $REPO_ROOT/program/VulkanDelegate.h $REPO_ROOT is repository as provided with *.vcxproj.

Exampleįilesystem-wise structure (as visible on-disk) Is there any way to sort source files into groups without making on-filesystem changes, that is in project view toolbox in CLion IDE?Ĭouldn't find anything in documentation so far, but it would be something alike to Code Hierarchy, but for.

I'm still pretty new to JetBrains IDE ecosystem, so I wondered whether there is something that could provide this kind of functionality out of box, or perhaps with a plugin. Now - I know that some larger CMake projects (as in solution/group of subprojects) often use plain filesystem subdirectories to further break-up its code in each subproject, but since some of "solutions" I'm trying to add CMake support to, consider of few hundred source files, I can't really go about refactoring everything manually and changing #include "service_foo.h" into #include service/service_foo.h in each of them.Īlso another thing to consider is that I'm not migrating solution to work with CMake - I'm adding support for CMake builds/CLion IDE support alongside MSBuild toolchain/VS IDE support, so I don't want to introduce any breaking changes. I've been trying to "switch" some solutions over to CLion, because of its multiplatform focus and trying to add support for CMake+GCC into already existing VS solutions, as no cross-platform IDE has native support for. Main merit being ability to directly #include "foo.h"

In Visual Studio IDE, for C++ solutions, you can use so called "filters" to simulate source files tree/directories, while usually keeping all source code for each project in each project's root.
