From f4bc162ed12d671a5201b9d0448ab32673889ef4 Mon Sep 17 00:00:00 2001 From: lotyp Date: Tue, 14 Mar 2023 14:57:02 +0200 Subject: [PATCH] feat: add auto-merge workflow --- .github/workflows/auto-merge-release.yaml | 27 +++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 .github/workflows/auto-merge-release.yaml diff --git a/.github/workflows/auto-merge-release.yaml b/.github/workflows/auto-merge-release.yaml new file mode 100644 index 0000000..729b174 --- /dev/null +++ b/.github/workflows/auto-merge-release.yaml @@ -0,0 +1,27 @@ +--- + +# https://github.com/peter-evans/enable-pull-request-automerge + +on: # yamllint disable-line rule:truthy + pull_request: + +permissions: + pull-requests: write + contents: write + +name: 🤞 Auto merge release + +jobs: + auto-merge: + if: github.actor == 'lotyp' && startsWith(github.head_ref, 'release-please--') + runs-on: ubuntu-latest + steps: + - name: 🤞 Auto-merge pull request + uses: peter-evans/enable-pull-request-automerge@v2 + with: + pull-request-number: ${{ github.event.pull_request.number }} + merge-method: merge + # to trigger other workflows, pass PAT token instead of GITHUB_TOKEN + token: ${{ secrets.PERSONAL_GITHUB_TOKEN }} + +...