From 78befb1dc92a65528c81053c690b0d0dd5be9ce4 Mon Sep 17 00:00:00 2001 From: Nicolas Pepin-Perreault Date: Wed, 24 Jul 2024 15:24:08 +0200 Subject: [PATCH] build: approve PR before merge --- .github/workflows/build-test.yml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-test.yml b/.github/workflows/build-test.yml index 70288ec30..abf98d0a4 100644 --- a/.github/workflows/build-test.yml +++ b/.github/workflows/build-test.yml @@ -192,14 +192,18 @@ jobs: - id: approve-and-merge-dependabot name: Approve and merge dependabot PR if: github.actor == 'dependabot[bot]' && (steps.metadata.outputs.update-type == 'version-update:semver-patch' || steps.metadata.outputs.update-type == 'version-update:semver-minor') - run: gh pr merge --auto --merge "$PR_URL" + run: | + gh pr review --approve "$PR_URL" + gh pr merge --auto --merge "$PR_URL" env: PR_URL: ${{github.event.pull_request.html_url}} GH_TOKEN: ${{secrets.GITHUB_TOKEN}} - id: approve-and-merge-backport name: Approve and merge backport PR if: github.actor != 'dependabot[bot]' - run: gh pr merge --auto --merge "$PR_URL" + run: | + gh pr review --approve "$PR_URL" + gh pr merge --auto --merge "$PR_URL" env: PR_URL: ${{github.event.pull_request.html_url}} GH_TOKEN: ${{secrets.GITHUB_TOKEN}}