From 11a0188b63f5912f39c04eeaa119e1113e7d9533 Mon Sep 17 00:00:00 2001 From: Colin Davidson Date: Mon, 16 Oct 2023 10:36:21 +0100 Subject: [PATCH] Updrade clang-tidy to 17 --- .github/workflows/run_pr_tests.yml | 10 +++------- CMakeLists.txt | 2 +- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/.github/workflows/run_pr_tests.yml b/.github/workflows/run_pr_tests.yml index 60b7be7be..fd75fb55c 100644 --- a/.github/workflows/run_pr_tests.yml +++ b/.github/workflows/run_pr_tests.yml @@ -108,10 +108,6 @@ jobs: llvm_version: 16 llvm_build_type: RelAssert - # installs clang-tidy - - name: setup-clang-tidy - run: - sudo apt-get install -y clang-tidy-12 # These need to match the configurations of build_pr_cache to use the cache effectively - name: build initial config files @@ -159,7 +155,7 @@ jobs: HEAD..origin/${{ github.base_ref }} | \ grep -P '\.(c|cc|cxx|cpp|h|hh|hpp|hxx)$'` | \ tee /dev/stderr | \ - parallel --verbose -- clang-tidy-12 --quiet -p "$PWD/build/" "{}" + parallel --verbose -- clang-tidy-17 --quiet -p "$PWD/build/" "{}" # ^ When updating the clang-tidy version, the version used by the cmake # target should match updated c.f. the `tidy` target @@ -174,11 +170,11 @@ jobs: - name: setup-ubuntu-clang-format run: - pip install clang-format==16.0.6 + pip install clang-format==17.0.0 - name: run clang-format run: | - # we've installed clang-format-16 in the docker via pip, which just installs it as clang-format, + # we've installed clang-format-17 in the docker via pip, which just installs it as clang-format, # so just use clang-format-diff and -b clang-format directly git fetch origin ${{ github.base_ref }} git diff -U0 --no-color origin/${{ github.base_ref }} | \ diff --git a/CMakeLists.txt b/CMakeLists.txt index f8d550c14..0bf88afb7 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -176,7 +176,7 @@ find_package(PythonInterp 3.6 REQUIRED) # When updating the version here, also update that used in the merge request # config find_package(ClangTools 16 COMPONENTS clang-format) -find_package(ClangTools 12 COMPONENTS clang-tidy) +find_package(ClangTools 15 COMPONENTS clang-tidy) if(TARGET ClangTools::clang-tidy) ca_option(CA_CLANG_TIDY_FLAGS STRING "Semi-color separated list of clang-tidy flags" "")