diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 28d582e..8c6e3a8 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -3,11 +3,11 @@ name: Automated Release on: - push: - branches: [main] + schedule: + - cron: 35 3 2 * * workflow_dispatch: # Serialize release runs. Each run's release-notes lower bound is the latest tag -# at the time its prepare job runs; two merges in quick succession would both +# at the time its prepare job runs; two runs in quick succession would both # read that bound before either run has tagged, producing overlapping notes. # Queueing (no cancel) lets the earlier release finish and create its tag first, # so the next run's notes start from that tag and carry only its own commits. @@ -19,7 +19,7 @@ jobs: name: Prepare Release runs-on: ubuntu-latest outputs: - needed: ${{ steps.gate.outputs.needed }} + needed: ${{ steps.gate.outputs.needed == 'true' && steps.quota.outputs.available == 'true' }} version: ${{ steps.version.outputs.version }} previous: ${{ steps.gate.outputs.last }} steps: @@ -32,9 +32,13 @@ jobs: uses: metio/ci/needs-release@4e1bc9f3d854998e07b63b20a49dd60e652c0d32 # 2026.10.30204559 with: paths: src/main/java pom.xml + - id: quota + name: Check Maven Central quota + if: steps.gate.outputs.needed == 'true' + uses: metio/ci/central-quota@4e1bc9f3d854998e07b63b20a49dd60e652c0d32 # 2026.10.30204559 - id: version name: Compute the next version - if: steps.gate.outputs.needed == 'true' + if: steps.gate.outputs.needed == 'true' && steps.quota.outputs.available == 'true' uses: metio/ci/calver@4e1bc9f3d854998e07b63b20a49dd60e652c0d32 # 2026.10.30204559 release: needs: [prepare]