From 68a6aef1553efce2b41ab89701102b3a6730d40f Mon Sep 17 00:00:00 2001 From: Michele Caini Date: Fri, 17 May 2024 11:52:07 +0200 Subject: [PATCH] workflow: * add linter job * bind both linter and iwyu to a specific branch --- .github/workflows/{analyzer.yml => tools.yml} | 24 +++++++++++++++++-- 1 file changed, 22 insertions(+), 2 deletions(-) rename .github/workflows/{analyzer.yml => tools.yml} (79%) diff --git a/.github/workflows/analyzer.yml b/.github/workflows/tools.yml similarity index 79% rename from .github/workflows/analyzer.yml rename to .github/workflows/tools.yml index 0e69d8dbb..ed9797a51 100644 --- a/.github/workflows/analyzer.yml +++ b/.github/workflows/tools.yml @@ -3,8 +3,7 @@ name: analyzer on: push: branches: - - master - - wip + - tools jobs: @@ -59,3 +58,24 @@ jobs: -DCMAKE_CXX_INCLUDE_WHAT_YOU_USE="include-what-you-use;-Xiwyu;--mapping_file=${GITHUB_WORKSPACE}/entt.imp;-Xiwyu;--no_fwd_decls;-Xiwyu;--verbose=1" \ .. make -j4 + + clang_tidy: + timeout-minutes: 30 + + runs-on: ubuntu-latest + continue-on-error: true + + steps: + - uses: actions/checkout@v4 + - name: Compile tests + working-directory: build + env: + CXX: clang++ + run: | + cmake -DENTT_BUILD_TESTING=ON -DENTT_BUILD_LIB=ON -DENTT_BUILD_EXAMPLE=ON -DENTT_USE_CLANG_TIDY=ON .. + make -j4 + - name: Run tests + working-directory: build + env: + CTEST_OUTPUT_ON_FAILURE: 1 + run: ctest -C Debug -j4