From 9e07b03b78f31788e3c6b6cbe70194d28d77c568 Mon Sep 17 00:00:00 2001 From: Dan Paulat Date: Thu, 28 Nov 2024 08:42:20 -0600 Subject: [PATCH] Add alternate reference for clang-format-check on pull request --- .github/workflows/clang-format-check.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/clang-format-check.yml b/.github/workflows/clang-format-check.yml index f3e883d6..dbc0c2c9 100644 --- a/.github/workflows/clang-format-check.yml +++ b/.github/workflows/clang-format-check.yml @@ -35,6 +35,6 @@ jobs: - name: Check Formatting shell: bash run: | - MERGE_BASE=$(git merge-base origin/develop ${{ github.ref }}) + MERGE_BASE=$(git merge-base origin/develop ${{ github.head_ref || github.ref }}) echo "Comparing against ${MERGE_BASE}" git clang-format-17 --diff --style=file -v ${MERGE_BASE}