Skip to content

Commit

Permalink
Fix AUTO_MERGE var calculation in the spring-merge-dependabot-pr.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
artembilan committed Feb 7, 2025
1 parent f6486bb commit 4c101b0
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions .github/workflows/spring-merge-dependabot-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,12 +67,17 @@ jobs:
gh pr edit ${{ github.event.pull_request.number }} --add-label "${{ inputs.developmentLabel }}"
gh pr edit ${{ github.event.pull_request.number }} --remove-label "${{ inputs.dependenciesLabel }}"
- id: is-auto-merge
- name: Determine auto-merge
id: is-auto-merge
run: |
AUTO_MERGE=${{ inputs.autoMerge || (inputs.autoMergeSnapshots && endsWith(steps.metadata.outputs.new-version, '-SNAPSHOT')) }}
if [ -z $AUTO_MERGE ]
then
AUTO_MERGE=$(gh pr view ${{ github.event.pull_request.number }} --json milestone -q '.milestone.number')
PR_MILESTONE=$(gh pr view ${{ github.event.pull_request.number }} --json milestone -q '.milestone.number')
if [ -z $PR_MILESTONE ]
then
AUTO_MERGE=true
fi
fi
echo autoMerge=$AUTO_MERGE >> $GITHUB_OUTPUT
Expand Down

0 comments on commit 4c101b0

Please sign in to comment.