Skip to content

Commit

Permalink
PR-into-next-branch.yml: only fetch the head commit from both branches
Browse files Browse the repository at this point in the history
  • Loading branch information
sergej-koscejev committed Nov 7, 2023
1 parent ab25702 commit 03f6b1b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion .github/workflows/PR-into-next-version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ jobs:
uses: actions/checkout@v3
with:
ref: ${{ inputs.to-branch }}
fetch-depth: 0

# actually merge from the previous branch
- name: Perform merge from ${{ inputs.from-version }} to ${{ inputs.to-version }}
Expand All @@ -41,6 +40,8 @@ jobs:
git config user.name 'github-actions[bot]'
git config user.email 'github-actions[bot]@users.noreply.github.com'
git fetch origin ${{ inputs.from-branch }} --depth=1
# actual merge operation
git merge --no-ff --message "Merge ${{ inputs.from-branch }}" origin/${{ inputs.from-branch }} -- || ( echo "Merge failed. Please merge manually!" ; exit 1 )
Expand Down

0 comments on commit 03f6b1b

Please sign in to comment.