From 7f7bf3981f044f281a48286ae6f2e22224e9da45 Mon Sep 17 00:00:00 2001 From: "Sidorov, Dmitry" Date: Wed, 15 Nov 2023 17:18:06 -0800 Subject: [PATCH] [NFC] Fix clang format automation after 68d618f90 The patch adds exit(1) in case if the clang-format reports an error and it breaks our pre-commit CI. Signed-off-by: Sidorov, Dmitry --- .github/workflows/check-code-style.yml | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/.github/workflows/check-code-style.yml b/.github/workflows/check-code-style.yml index 622f2199f0..198f160e66 100644 --- a/.github/workflows/check-code-style.yml +++ b/.github/workflows/check-code-style.yml @@ -83,14 +83,7 @@ jobs: id: run-clang-format run: | cat diff-to-inspect.txt | /usr/share/clang/clang-format-${{ env.LLVM_VERSION }}/clang-format-diff.py \ - -p1 -binary clang-format-${{ env.LLVM_VERSION }} > clang-format.patch - if [ -s clang-format.patch ]; then - echo "clang-format found incorrectly formatted code:" - cat clang-format.patch; - exit 1; - else - rm clang-format.patch # to avoid uploading empty file - fi + -p1 -binary clang-format-${{ env.LLVM_VERSION }} - name: Run clang-tidy # By some reason, GitHub Actions automatically include "success()"