Skip to content

Commit

Permalink
Try and Approve with Github
Browse files Browse the repository at this point in the history
I'm not sure if this is allowed, but zorgbort wasn't allowed to approve
the PR because they created it, and CI won't run if github creates the
PR. So let's try this.
  • Loading branch information
jrjohnson committed Jul 26, 2024
1 parent 440ba22 commit d5e3791
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions .github/workflows/update-transitive-dependencies.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@ on:
jobs:
update:
runs-on: macos-latest

permissions:
pull-requests: write
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
Expand Down Expand Up @@ -37,10 +38,13 @@ jobs:
[1]: https://github.com/peter-evans/create-pull-request
branch: auto-update-dependencies
labels: dependencies,run percy tests
- name: Approve Pull Request
if: steps.cpr.outputs.pull-request-operation == 'created'
run: gh pr review --approve -b "Auto Approved" ${{ steps.cpr.outputs.pull-request-number }}
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Enable Pull Request Automerge
if: steps.cpr.outputs.pull-request-operation == 'created'
run: |
gh pr review --approve -b "Auto Approved by Zorgbort" ${{ steps.cpr.outputs.pull-request-number }}
gh pr merge --merge --auto ${{ steps.cpr.outputs.pull-request-number }}
run: gh pr merge --merge --auto ${{ steps.cpr.outputs.pull-request-number }}
env:
GH_TOKEN: ${{ secrets.ZORGBORT_TOKEN }}

0 comments on commit d5e3791

Please sign in to comment.