We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bf4eef9 commit 5f9da7cCopy full SHA for 5f9da7c
.github/workflows/build-deploy-changes.yaml
@@ -49,7 +49,12 @@ jobs:
49
base_sha=$(git merge-base origin/${{ github.event.pull_request.base.ref }} ${{ github.event.pull_request.head.sha }})
50
head_sha="${{ github.event.pull_request.head.sha }}"
51
else
52
- base_sha="${{ github.event.before }}"
+ if [ "${{ github.event.before }}" = "0000000000000000000000000000000000000000" ]; then
53
+ # Get the previous commit on branch
54
+ base_sha=$(git rev-parse ${{ github.sha }}^)
55
+ else
56
+ base_sha="${{ github.event.before }}"
57
+ fi
58
head_sha="${{ github.sha }}"
59
fi
60
0 commit comments