24 lines
671 B
YAML
24 lines
671 B
YAML
name: On labeled PR
|
|
|
|
on:
|
|
pull_request:
|
|
types:
|
|
- labeled
|
|
|
|
jobs:
|
|
automerge:
|
|
name: Auto Merge
|
|
if: "${{ github.event.label.name == 'automerge' && github.repository_owner == 'JabRef' }}"
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Approve PR
|
|
run: gh pr review --approve "$PR_URL"
|
|
env:
|
|
PR_URL: ${{github.event.pull_request.html_url}}
|
|
GITHUB_TOKEN: ${{secrets.GH_TOKEN_JABREF_MACHINE_PR_APPROVE}}
|
|
- name: Merge PR
|
|
run: gh pr merge --auto --squash "$PR_URL"
|
|
env:
|
|
PR_URL: ${{github.event.pull_request.html_url}}
|
|
GITHUB_TOKEN: ${{secrets.GH_TOKEN_UPDATE_GRADLE_WRAPPER}}
|