Skip to content

Commit 587ca32

Browse files
authored
fix: Attempt to fix broken release process. (#1414)
1 parent 839bd78 commit 587ca32

1 file changed

Lines changed: 13 additions & 3 deletions

File tree

.github/workflows/dist-pr.yml

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,13 +40,23 @@ jobs:
4040
git config --global user.name 'googlemaps-bot'
4141
git config --global user.email 'googlemaps-bot@google.com'
4242
43-
- name: Create Pull Request
43+
- name: Create Pull Request, Approve, and Enable Auto-Merge
4444
run: |
45-
gh pr create \
45+
PR_URL=$(gh pr create \
4646
--base main \
4747
--head temp-build-branch \
4848
--title "chore: automated output update (dist)" \
4949
--body "This PR contains updated build output from the dist branch." \
50-
--label "automated pr,dist-update"
50+
--label "automated pr,dist-update")
51+
52+
echo "PR created at $PR_URL"
53+
54+
# Approve the PR using the Approver Token
55+
GH_TOKEN=${{ secrets.GH_APPROVER_TOKEN }} gh pr review --approve "$PR_URL"
56+
echo "PR approved."
57+
58+
# Enable auto-merge using the Merge Token
59+
gh pr merge --auto --merge "$PR_URL"
60+
echo "Auto-merge enabled."
5161
env:
5262
GH_TOKEN: ${{ secrets.GH_MERGE_TOKEN }}

0 commit comments

Comments
 (0)