diff --git a/.github/workflows/dependabot-auto-merge.yml b/.github/workflows/dependabot-auto-merge.yml new file mode 100644 index 0000000..1d9e126 --- /dev/null +++ b/.github/workflows/dependabot-auto-merge.yml @@ -0,0 +1,22 @@ +name: Dependabot Auto-merge + +on: + pull_request: + branches: ["main"] + +permissions: + contents: write + pull-requests: write + +jobs: + auto-merge: + name: Auto-merge + runs-on: ubuntu-latest + if: github.actor == 'dependabot[bot]' + + steps: + - name: Enable auto-merge + run: gh pr merge --auto --squash "$PR_URL" + env: + PR_URL: ${{ github.event.pull_request.html_url }} + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.mergify.yml b/.mergify.yml deleted file mode 100644 index 6f08bfe..0000000 --- a/.mergify.yml +++ /dev/null @@ -1,28 +0,0 @@ -pull_request_rules: - - name: Auto-merge dependabot minor/patch - conditions: - - author = dependabot[bot] - - check-success = Format - - check-success = Lint - - check-success = Type Check - - check-success = Test - actions: - approve: - message: Auto-approving dependabot update - merge: - method: squash - - - name: Auto-merge release-please on Mondays - conditions: - - author = github-actions[bot] - - label = "autorelease: pending" - - check-success = Format - - check-success = Lint - - check-success = Type Check - - check-success = Test - - current-day-of-week = Monday - actions: - approve: - message: Auto-approving scheduled release - merge: - method: merge