I have Jenkins running cmake with
-DCMAKE_C_CLANG_TIDY=clang-tidy -DCMAKE_CXX_CLANG_TIDY=clang-tidy but, since the warnings format of clang-tidy is basically the same than the one from gcc/clang, the Jenkins Warnings NG plugin can’t differentiate between them.
We use incremental builds and, since clang-tidy can be quite time consuming, is really nice that cmake will run it only on the files that have changed. I don’t want to lose that, but I would like Jenkins to show me the clang-tidy warnings as a different category to the compiler warnings. So I would like to be able to do something similar to:
cmake --build . --target clang-tidy 2>&1 | tee clang-tidy.warnings
cmake --build . 2>&1 | tee compiler.warnings
i.e. first run clang-tidy only. Is it possible?