From 86f4e36c7c9bcef6dba304e172dd987ec256997a Mon Sep 17 00:00:00 2001 From: Anne Beth Andersen <195699472+abla86@users.noreply.github.com> Date: Tue, 29 Sep 2026 20:29:18 +0200 Subject: [PATCH] ci: automate safe Dependabot merges --- .../workflows/dependabot-auto-maintenance.yml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 .github/workflows/dependabot-auto-maintenance.yml diff --git a/.github/workflows/dependabot-auto-maintenance.yml b/.github/workflows/dependabot-auto-maintenance.yml new file mode 100644 index 0000000..350e29a --- /dev/null +++ b/.github/workflows/dependabot-auto-maintenance.yml @@ -0,0 +1,19 @@ +name: Dependabot Auto-Maintenance +on: + pull_request: + types: [opened, synchronize, reopened] +permissions: + contents: write + pull-requests: write +jobs: + dependabot: + if: github.actor == 'dependabot[bot]' && startsWith(github.event.pull_request.head.ref, 'dependabot/') + runs-on: ubuntu-latest + steps: + - name: Enable auto-merge for safe dependency updates + env: + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} + PR: ${{ github.event.pull_request.number }} + run: | + set -euo pipefail + gh pr merge "$PR" --auto --squash --repo "$GITHUB_REPOSITORY"