From 915109fbb4b288548d31e131fbaba4c9c66ed12c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bern=C3=A1t=20G=C3=A1bor?= Date: Fri, 6 Nov 2026 08:25:26 -0800 Subject: [PATCH] =?UTF-8?q?=F0=9F=91=B7=20ci:=20dry-run=20the=20release=20?= =?UTF-8?q?in=20the=20PR=20gate?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Release preparation installs prek hooks under the seven-day cooldown, links fragments and builds the changelog; no pull request check did, so a change could merge green and fail the next release (simplint#55). The gate now calls the prepare workflow with dry-run, which assembles the release and skips the push. --- .github/workflows/check.yaml | 10 +++++++++- .github/workflows/prepare-release.yaml | 11 +++++++++-- 2 files changed, 18 insertions(+), 3 deletions(-) diff --git a/.github/workflows/check.yaml b/.github/workflows/check.yaml index b9b2073..31ff75f 100644 --- a/.github/workflows/check.yaml +++ b/.github/workflows/check.yaml @@ -33,10 +33,18 @@ jobs: {"env": "dev"}, {"env": "pkg_meta"} ] + release: + name: 🏷️ Release dry run + uses: $/.github/workflows/prepare-release.yaml + permissions: + contents: read + pull-requests: read + with: + dry-run: true gate: name: 🚦 Required checks pass if: ${{ !cancelled() }} # codespell:ignore cancelled - needs: [test] + needs: [test, release] runs-on: ubuntu-26.04 permissions: {} steps: diff --git a/.github/workflows/prepare-release.yaml b/.github/workflows/prepare-release.yaml index 49410a3..ab1f4d7 100644 --- a/.github/workflows/prepare-release.yaml +++ b/.github/workflows/prepare-release.yaml @@ -12,14 +12,21 @@ on: - minor - patch default: auto + workflow_call: + inputs: + dry-run: + description: Assemble the release without pushing, for the pull request gate + type: boolean + required: true permissions: contents: read pull-requests: read jobs: prepare: name: 🏷️ Prepare Towncrier release - uses: tox-dev/github-workflows/.github/workflows/prepare-towncrier-release.yaml@bceb5c005e19823dc8835f536f53f172ae223927 # 6.5.0 + uses: tox-dev/github-workflows/.github/workflows/prepare-towncrier-release.yaml@2a3b863f4563ce9891d2cee1ed381b6f82654836 # 6.6.0 with: - bump: ${{ inputs.bump }} + bump: ${{ inputs.bump || 'auto' }} + dry-run: ${{ inputs.dry-run == true }} secrets: RELEASE_APP_PRIVATE_KEY: ${{ secrets.RELEASE_APP_PRIVATE_KEY }}