From 7c05e0a7707e7a76d9b07d053ee317fdd83fd925 Mon Sep 17 00:00:00 2001 From: Alexander Sysoev Date: Tue, 18 Feb 2025 14:20:12 +0100 Subject: [PATCH] Enable auto-merge instead of merge queue --- .github/workflows/validate-pr.yml | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/.github/workflows/validate-pr.yml b/.github/workflows/validate-pr.yml index ed0d53cb..885eb775 100644 --- a/.github/workflows/validate-pr.yml +++ b/.github/workflows/validate-pr.yml @@ -1,11 +1,9 @@ name: Validate PR -# https://github.com/orgs/community/discussions/51120#discussioncomment-8623798 on: - merge_group: workflow_dispatch: pull_request: - types: [enqueued] + types: [auto_merge_enabled] jobs: validate-pr: @@ -23,3 +21,10 @@ jobs: - name: Clean Build with Gradle run: ./gradlew clean build + + - name: Disable Auto-Merge on Fail + if: failure() + run: gh pr merge --disable-auto "$PR_URL" + env: + PR_URL: ${{github.event.pull_request.html_url}} + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}