From 589cbe4b199e9aa6aa58143703a9f2290378389e Mon Sep 17 00:00:00 2001 From: konstantin Date: Mon, 4 Dec 2023 09:06:34 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=A4=96Add=20automatic=20approval=20&=20sq?= =?UTF-8?q?uash=20merge=20workflow=20for=20dependabot=20PRs?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/dependabot_automerge.yml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 .github/workflows/dependabot_automerge.yml diff --git a/.github/workflows/dependabot_automerge.yml b/.github/workflows/dependabot_automerge.yml new file mode 100644 index 0000000..68d80b7 --- /dev/null +++ b/.github/workflows/dependabot_automerge.yml @@ -0,0 +1,18 @@ +name: Dependabot auto-approve / -merge +on: pull_request + +jobs: + dependabot: + permissions: + contents: write + pull-requests: write + runs-on: ubuntu-latest + env: + PR_URL: ${{github.event.pull_request.html_url}} + GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} + if: ${{ github.actor == 'dependabot[bot]' }} + steps: + - name: Approve a PR + run: gh pr review --approve "$PR_URL" + - name: Enable auto-merge for Dependabot PRs + run: gh pr merge --auto --squash "$PR_URL"