Closed oSumAtrIX closed 10 months ago
I'm not familiar with cmake, Is this rule build@CMakeLists.txt
generic? @oSumAtrIX
CMakeCache.txt,CMakeFiles@CMakeLists.txt
should be sufficient for CMake
I disagree with you, I just checked out today's c++ trending projects, there are several projects that uses the build
dir:
@oSumAtrIX
You can run cmake everywhere including in the top root directory. Include build as well
If the rule is CMakeCache.txt,CMakeFiles@CMakeLists.txt
, projclean only searches CMakeCache.txt
/CMakeFiles
in the directory that contains CMakeLists.txt
, not recursively.
For example, projclean CMakeCache.txt,CMakeFiles@CMakeLists.txt
won't clean up anything below
├── build
│ ├── CMakeCache.txt
│ └── CMakeFiles
└── CMakeLists.txt
But projclean build@CMakeLists.txt
will clean up the build
directory.
I meant that CMake can be run in the top root directory but also commonly in a build folder to not poison the project folder. Projclean should ideally handle both scenarios
cmake generates a lot of files, not only CMakeCache.txt and CMakeFiles. It makes no sense at all to just clean up part of it.
That's the most common files generated and if done in the root of the project, just cleaning build wouldn't cut it, like previously said, ideally you consider both cases
I've always believed that if you can only clean up parts of a project, you might as well not clean it up at all.
I will add the rule build@CMakeLists.txt
. If users want to clean CMakeFiles or CMakeCache.txt
then they can use custom rules
I'd say Make/CMake generated files can be quite big, so they'd be a good candidate for https://github.com/sigoden/projclean.