From 78189099b24d1f3a81d8866801c2821e04d05ba2 Mon Sep 17 00:00:00 2001 From: Nikos Date: Fri, 8 Sep 2023 15:03:41 +0300 Subject: [PATCH] ci: fix auto merge logic --- .github/workflows/auto-approver.yaml | 5 ++--- renovate.json | 3 ++- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/auto-approver.yaml b/.github/workflows/auto-approver.yaml index f5b67511..b51c46db 100644 --- a/.github/workflows/auto-approver.yaml +++ b/.github/workflows/auto-approver.yaml @@ -17,9 +17,8 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.PAT_TOKEN }} - name: Enable automerge if required + if: startsWith(github.ref_name, 'renovate/auto-') run: | - if [[ $(gh pr view --json body | grep "\*\*Automerge\*\*: Enabled") ]]; then - gh pr merge --auto --merge || true - fi + gh pr merge --auto --merge || true env: GITHUB_TOKEN: ${{ secrets.PAT_TOKEN }} diff --git a/renovate.json b/renovate.json index 9e699d7f..d87ccaeb 100644 --- a/renovate.json +++ b/renovate.json @@ -13,5 +13,6 @@ ], "automergeType": "pr", "rebaseWhen": "behind-base-branch", - "automerge": true + "automerge": true, + "additionalBranchPrefix": "auto-" } \ No newline at end of file