mirror of
https://github.com/floci-io/floci.git
synced 2026-11-23 06:00:46 -05:00
Consolidates three open dependabot PRs into one change so CI runs once instead of three times, and the workflow files are touched by a single commit rather than three overlapping ones. - #2908 actions-minor-patch group, five workflows - #2910 actions/setup-java 5.6.0 to 6.0.0 - #2909 actions/setup-node 6.0.0 to 7.0.0 Every changed line is a `uses:` reference: setup-buildx x8, setup-graalvm x7, login-action x4, checkout x4, build-push-action x3, setup-java x2, setup-node x1. Nothing outside .github/workflows is touched. The maven-minor-patch group (#2906) is deliberately left out: it crosses a Quarkus minor version and wants its own branch and a full test run.
76 lines
2.7 KiB
YAML
76 lines
2.7 KiB
YAML
name: Release Cut
|
|
|
|
# One-button release from main.
|
|
#
|
|
# Manually dispatched: semantic-release analyzes the Conventional Commits on
|
|
# main, bumps pom.xml (via the exec plugin running `mvn versions:set`), writes
|
|
# CHANGELOG.md, commits those files, tags the release (tagFormat: ${version}),
|
|
# and creates the GitHub Release. The tag push then fires release.yml exactly
|
|
# as a manual tag push does today.
|
|
#
|
|
# GH_TOKEN must be a fine-grained PAT with contents:write. The default
|
|
# GITHUB_TOKEN cannot be used: tags pushed with it do not trigger other
|
|
# workflows (GitHub's recursion guard), so release.yml would never run.
|
|
#
|
|
# Maven note: the exec plugin invokes `mvn versions:set`; ubuntu-latest ships
|
|
# a system mvn, which is sufficient for that goal.
|
|
#
|
|
# The toolchain is pinned: .github/release-tooling/package-lock.json is the
|
|
# only source of the semantic-release dependency tree (npm ci --ignore-scripts),
|
|
# so the job that holds the write PAT never resolves mutable versions.
|
|
#
|
|
# Required secrets: GH_TOKEN
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
inputs:
|
|
dry-run:
|
|
description: 'Dry run (compute the next version and release notes without releasing)'
|
|
type: boolean
|
|
default: false
|
|
|
|
permissions:
|
|
contents: write
|
|
|
|
# Serialize release cuts: a second dispatch queues behind the first instead of
|
|
# racing it to the same version/tag. No cancel-in-progress — never kill a
|
|
# mid-flight release. GitHub keeps at most ONE pending run per group, so if
|
|
# several dispatches pile up, only the latest pending one runs — intentional:
|
|
# duplicate queued release cuts are redundant by definition (the surviving run
|
|
# re-analyzes main and releases whatever is unreleased).
|
|
concurrency:
|
|
group: release-cut
|
|
|
|
jobs:
|
|
release:
|
|
name: Cut release from main
|
|
runs-on: ubuntu-latest
|
|
# semantic-release comments on and labels every issue and PR in the release,
|
|
# which is roughly two API writes each. A 278-PR release took ~22 minutes.
|
|
timeout-minutes: 60
|
|
|
|
steps:
|
|
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
with:
|
|
ref: main
|
|
token: ${{ secrets.GH_TOKEN }}
|
|
fetch-depth: 0
|
|
|
|
- uses: actions/setup-java@dd06d9cba3e5552c54d9f8ea23572deb30010f7c # v6.0.0
|
|
with:
|
|
java-version: '25'
|
|
distribution: 'temurin'
|
|
cache: maven
|
|
|
|
- uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0
|
|
with:
|
|
node-version: 22
|
|
|
|
- name: Install the pinned release toolchain
|
|
run: npm ci --prefix .github/release-tooling --ignore-scripts
|
|
|
|
- name: Run semantic-release
|
|
run: ./.github/release-tooling/node_modules/.bin/semantic-release ${{ inputs.dry-run && '--dry-run' || '' }}
|
|
env:
|
|
GH_TOKEN: ${{ secrets.GH_TOKEN }}
|