From d98a26894b4e682108c2c9c1c3a48d55d2548f59 Mon Sep 17 00:00:00 2001 From: Ellie Hermaszewska Date: Thu, 24 Oct 2024 21:15:38 +0800 Subject: [PATCH] add clang-format to ci formatting check --- .github/workflows/check-formatting.yml | 7 +++++++ include/slang.h | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/workflows/check-formatting.yml b/.github/workflows/check-formatting.yml index 99b8ff84ef..731ede1028 100644 --- a/.github/workflows/check-formatting.yml +++ b/.github/workflows/check-formatting.yml @@ -11,4 +11,11 @@ jobs: steps: - uses: actions/checkout@v4 - run: pip3 install gersemi + - name: install clang-format + run: | + tmpdir=$(mktemp -d) + curl -L -o "$tmpdir/clang-format" https://github.com/muttleyxd/clang-tools-static-binaries/releases/download/master-32d3ac78/clang-format-18_linux-amd64 + echo "660b67d7460cc77254343b7676d2e44dc65140221361346ee09e365526336747877e2c3e94062771244ea4320de29b42ad8be3ed0eb93c8c7b7ba5fe1de3e961 $tmpdir/clang-format" | sha512sum --check + chmod +x "$tmpdir/clang-format" + echo "$tmpdir" >> $GITHUB_PATH - run: ./extras/formatting.sh --check-only diff --git a/include/slang.h b/include/slang.h index 9c9a00585a..7503f2ed02 100644 --- a/include/slang.h +++ b/include/slang.h @@ -933,7 +933,7 @@ typedef uint32_t SlangSizeT; DumpRepro, DumpReproOnError, ExtractRepro, - LoadRepro, + LoadRepro , LoadReproDirectory, ReproFallbackDirectory,