Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use depth 100 #685

Merged
merged 1 commit into from
Nov 7, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion .github/workflows/PR-into-next-version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,13 @@ jobs:
runs-on: ubuntu-latest
steps:
# checkout the target branch
# Only fetch 100 commits, assuming that if the difference between branches is more than 100 commits then they
# probably won't be automergeable anyway.
- name: Checkout ${{ inputs.to-version }}
uses: actions/checkout@v3
with:
ref: ${{ inputs.to-branch }}
fetch-depth: 100

# actually merge from the previous branch
- name: Perform merge from ${{ inputs.from-version }} to ${{ inputs.to-version }}
Expand All @@ -40,7 +43,7 @@ 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
git fetch origin ${{ inputs.from-branch }} --depth=100

# 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