diff --git a/.github/workflows/format.yml b/.github/workflows/format.yml index 6e92c7bb97..2d13710723 100644 --- a/.github/workflows/format.yml +++ b/.github/workflows/format.yml @@ -4,8 +4,7 @@ on: [pull_request] jobs: clang-format: - # We need at least 20.04 to install clang-format-11. - runs-on: ubuntu-20.04 + runs-on: ubuntu-24.04 steps: - uses: actions/checkout@v2 with: @@ -16,10 +15,12 @@ jobs: env: DEBIAN_FRONTEND: noninteractive run: | - sudo apt update -y - sudo apt install -y clang-format-11 - sudo update-alternatives --install /usr/bin/clang-format clang-format /usr/bin/clang-format-11 100 - sudo update-alternatives --install /usr/bin/git-clang-format git-clang-format /usr/bin/git-clang-format-11 100 + sudo apt update + sudo apt install -y clang-format-18 + sudo update-alternatives --install /usr/bin/clang-format \ + clang-format /usr/bin/clang-format-18 100 + sudo update-alternatives --install /usr/bin/git-clang-format \ + git-clang-format /usr/bin/git-clang-format-18 100 - name: Run clang-format on changed files run: | set -x