2021-09-21 21:46:43 +03:00
|
|
|
name: "prautomerge"
|
2021-09-16 11:03:10 +03:00
|
|
|
|
2021-10-27 15:23:26 +03:00
|
|
|
on: pull_request_target
|
2021-09-16 11:03:10 +03:00
|
|
|
|
|
|
|
permissions:
|
|
|
|
pull-requests: write
|
2021-10-27 15:23:26 +03:00
|
|
|
contents: write
|
2021-09-16 11:03:10 +03:00
|
|
|
|
|
|
|
jobs:
|
2021-10-27 15:23:26 +03:00
|
|
|
dependabot:
|
2021-09-16 11:03:10 +03:00
|
|
|
runs-on: ubuntu-latest
|
2021-10-27 15:23:26 +03:00
|
|
|
if: ${{ github.actor == 'dependabot[bot]' }}
|
2021-09-16 11:03:10 +03:00
|
|
|
steps:
|
2021-10-27 15:23:26 +03:00
|
|
|
- name: Dependabot metadata
|
|
|
|
id: metadata
|
|
|
|
uses: dependabot/fetch-metadata@v1.1.1
|
2021-09-16 11:03:10 +03:00
|
|
|
with:
|
2021-10-27 15:23:26 +03:00
|
|
|
github-token: "${{ secrets.GITHUB_TOKEN }}"
|
|
|
|
- name: Enable auto-merge for Dependabot PRs
|
|
|
|
if: ${{contains(steps.metadata.outputs.dependency-names, 'go.unistack.org')}}
|
|
|
|
run: gh pr merge --auto --merge "$PR_URL"
|
|
|
|
env:
|
|
|
|
PR_URL: ${{github.event.pull_request.html_url}}
|
|
|
|
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
|