about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--.github/workflows/check-by-name.yml4
1 files changed, 3 insertions, 1 deletions
diff --git a/.github/workflows/check-by-name.yml b/.github/workflows/check-by-name.yml
index 90ab843839f62..9c46ecea6916b 100644
--- a/.github/workflows/check-by-name.yml
+++ b/.github/workflows/check-by-name.yml
@@ -19,11 +19,13 @@ jobs:
     steps:
       - name: Resolving the merge commit
         run: |
-          if result=$(git ls-remote --exit-code ${{ github.event.pull_request.base.repo.clone_url }} refs/pull/${{ github.event.pull_request.number }}/merge); then
+          if result=$(git ls-remote --exit-code ${{ github.event.pull_request.base.repo.clone_url }} refs/pull/${{ github.event.pull_request.number }}/merge 2>&1); then
             mergedSha=$(cut -f1 <<< "$result")
             echo "The PR appears to not have any conflicts, checking the merge commit $mergedSha"
           else
             echo "The PR may have a merge conflict"
+            echo "'git ls-remote' output was:"
+            echo "$result"
             exit 1
           fi
           echo "mergedSha=$mergedSha" >> "$GITHUB_ENV"