2023-10-04 17:41:39 +03:00
|
|
|
name: Dependabot auto-merge
|
|
|
|
on: pull_request
|
|
|
|
|
2024-05-09 14:52:37 +03:00
|
|
|
concurrency:
|
|
|
|
group: ${{ github.workflow }}-${{ (github.event.pull_request && github.event.pull_request.number) || github.ref || github.run_id }}
|
|
|
|
cancel-in-progress: true
|
|
|
|
|
2023-10-04 17:41:39 +03:00
|
|
|
permissions:
|
|
|
|
contents: write
|
|
|
|
pull-requests: write
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
dependabot:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
if: ${{ github.actor == 'dependabot[bot]' }}
|
|
|
|
steps:
|
|
|
|
- name: Dependabot metadata
|
|
|
|
id: metadata
|
2024-07-19 19:13:47 +03:00
|
|
|
uses: dependabot/fetch-metadata@dbb049abf0d677abbd7f7eee0375145b417fdd34 # v2.2.0
|
2023-10-04 17:41:39 +03:00
|
|
|
with:
|
|
|
|
github-token: "${{ secrets.GITHUB_TOKEN }}"
|
|
|
|
- name: Enable auto-merge for Dependabot PRs
|
|
|
|
if: ${{steps.metadata.outputs.update-type == 'version-update:semver-minor' || steps.metadata.outputs.update-type == 'version-update:semver-patch'}}
|
|
|
|
run: gh pr merge --auto --merge "$PR_URL"
|
|
|
|
env:
|
|
|
|
PR_URL: ${{github.event.pull_request.html_url}}
|
2024-01-08 19:45:02 +03:00
|
|
|
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
|