diff --git a/.github/workflows/lein-test.yaml b/.github/workflows/lein-test.yaml index bcc76cc..9b6dc75 100644 --- a/.github/workflows/lein-test.yaml +++ b/.github/workflows/lein-test.yaml @@ -52,3 +52,20 @@ jobs: uses: re-actors/alls-green@release/v1 with: jobs: ${{ toJSON(needs) }} + + automerge: + name: Enable auto-merge + if: github.event_name == 'pull_request' && (github.event.pull_request.user.login == 'dependabot[bot]' || github.event.pull_request.user.login == 'renovate[bot]') + needs: + - tests + runs-on: ubuntu-24.04 + permissions: + contents: write + pull-requests: write + steps: + - name: Enable auto-merge for PR + env: + GH_TOKEN: ${{ github.token }} + PR_URL: ${{ github.event.pull_request.html_url }} + PR_HEAD_SHA: ${{ github.event.pull_request.head.sha }} + run: gh pr merge --auto --merge --match-head-commit "$PR_HEAD_SHA" "$PR_URL"