Skip to content

Dependabot auto-merge #151

Dependabot auto-merge

Dependabot auto-merge #151

name: Dependabot auto-merge
on:
workflow_run:
workflows:
- 'CI Checks'
branches:
- 'dependabot/**'
types:
- completed
permissions:
pull-requests: write
contents: write
jobs:
dependabot:
runs-on: ubuntu-latest
if: ${{ github.actor == 'dependabot[bot]' && github.event.workflow_run.conclusion == 'success' }}
steps:
- uses: actions/checkout@v2
with:
ref: ${{ github.event.workflow_run.head_branch }}
- name: Auto-approve Dependabot PR
run: gh pr review --approve ${{ github.event.workflow_run.head_branch }}
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
- name: Auto-merge Dependabot PR
run: gh pr merge --auto --squash ${{ github.event.workflow_run.head_branch }}
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}