Skip to content

Workflow file for this run

name: Auto approve & Merge
on: pull_request_target
permissions:
pull-requests: write
contents: write
jobs:
approve-merge:
runs-on: ubuntu-latest
steps:
- name: Generate App token
id: generated_token
uses: tibdex/github-app-token@v2.1.0
with:
app_id: ${{ secrets.APP_ID }}
private_key: ${{ secrets.PRIVATE_KEY }}
- name: Approve the PR
uses: hmarr/auto-approve-action@v4
with:
github-token: ${{ secrets.BOT }}
- name: Enable auto-merge for PR
run: gh pr merge --auto "$PR_URL" --merge
env:
PR_URL: ${{ github.event.pull_request.html_url }}
GITHUB_TOKEN: ${{ steps.generated_token.outputs.token }}