Skip to content

Commit e8c38f0

Browse files
Merge pull request #2239 from bcgov/feature/ALCS-2227-adjust-dependabot
ALCS-2227: Adjust dependabot workflow
2 parents 499b323 + b31e158 commit e8c38f0

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

.github/workflows/auto-merge-dependabot.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,9 @@ jobs:
2424
- name: Auto-merge Dependabot PR
2525
env:
2626
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
27-
HEAD_BRANCH: ${{ github.event.workflow_run.head_branch }}
2827
run: |
29-
# Get PR number from branch name
30-
PR_NUMBER=$(echo "$HEAD_BRANCH" | grep -o '[0-9]\+' || echo '')
28+
# Get PR number from the workflow run event
29+
PR_NUMBER=${{ github.event.workflow_run.pull_requests[0].number }}
3130
3231
if [ -n "$PR_NUMBER" ]; then
3332
# Approve PR

0 commit comments

Comments
 (0)