From a729c15e9dce9f5116a38afc66329ab2ca4cea54 Mon Sep 17 00:00:00 2001 From: Ellie Hermaszewska Date: Tue, 29 Oct 2024 13:59:28 +0800 Subject: preparation for clang format (#5422) * Clang-format excludes * Add .clang-format * Don't clang-format in external * Missing includes and forward declarations * Replace wonky include-once macro name * neaten include naming * Add clang-format to formatting script * Add xargs and diff to required binaries * add clang-format to ci formatting check * Add max version check to formatting script * temporarily disable checking formatting for cpp files --- .github/actions/format-setup/action.yml | 2 +- .github/workflows/check-formatting.yml | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) (limited to '.github') diff --git a/.github/actions/format-setup/action.yml b/.github/actions/format-setup/action.yml index 58eddac77..d99be4d3a 100644 --- a/.github/actions/format-setup/action.yml +++ b/.github/actions/format-setup/action.yml @@ -16,6 +16,6 @@ runs: tmpdir=$(mktemp -d) curl -L -H "Authorization: token ${{github.token}}" \ -o "$tmpdir/clang-format" \ - https://github.com/shader-slang/slang-binaries/raw/4e88845ec51641b4c92e68027e359090bdb219e0/clang-format/x86_64-linux/bin/clang-format + https://github.com/shader-slang/slang-binaries/raw/306d22efc0f5f72c7230b0b6b7c99f03c46995bd/clang-format/x86_64-linux/bin/clang-format chmod +x "$tmpdir/clang-format" echo "$tmpdir" >> $GITHUB_PATH diff --git a/.github/workflows/check-formatting.yml b/.github/workflows/check-formatting.yml index c923d1855..f4226cd8c 100644 --- a/.github/workflows/check-formatting.yml +++ b/.github/workflows/check-formatting.yml @@ -10,7 +10,5 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - - name: Setup - uses: ./.github/actions/format-setup + - uses: ./.github/actions/format-setup - run: ./extras/formatting.sh --check-only - -- cgit v1.2.3