File tree Expand file tree Collapse file tree 1 file changed +3
-8
lines changed Expand file tree Collapse file tree 1 file changed +3
-8
lines changed Original file line number Diff line number Diff line change @@ -183,8 +183,6 @@ jobs:
183183 steps :
184184 - uses : actions/checkout@v4
185185 with :
186- # Required because otherwise there are always changes detected when executing diff/rev-list
187- fetch-depth : 0
188186 # If no PAT is used the following error occurs on a push:
189187 # refusing to allow a GitHub App to create or update workflow `.github/workflows/xxx.yml` without `workflows` permission
190188 token : ${{ secrets.UPDATE_FROM_TEMPLATE_PAT }}
@@ -210,7 +208,7 @@ jobs:
210208
211209 echo "Checking if update-branch-merged exists"
212210 git fetch
213- if [[ $(git ls-remote --exit-code --heads origin ${{ env.UPDATE_BRANCH_MERGED }}) ]]; then
211+ if [[ $(git rev-parse origin/ ${{ env.UPDATE_BRANCH_MERGED }}) ]]; then
214212 echo "Branch origin/${{ env.UPDATE_BRANCH_MERGED }} is missing"
215213 exit 0
216214 fi
@@ -271,11 +269,8 @@ jobs:
271269 base_branch=$(git branch --show-current)
272270 echo "Base branch is $base_branch"
273271
274- echo "Fully fetching..."
275- git fetch --unshallow || true
276- git config remote.origin.fetch "+refs/heads/*:refs/remotes/origin/*"
277- git fetch origin
278-
272+ echo "Fetching..."
273+ git fetch
279274 if [[ $(git rev-parse origin/${{ env.UPDATE_BRANCH_MERGED }}) ]]; then
280275 echo "Branch origin/${{ env.UPDATE_BRANCH_MERGED }} is missing"
281276 exit 0
You can’t perform that action at this time.
0 commit comments