Auto Release Workflow

January 23, 2026 ยท View on GitHub

This directory contains a reusable GitHub Actions workflow for automated releases based on semantic versioning labels.

Usage in other repositories

To use this workflow in your repository, create .github/workflows/auto-release.yml:

name: Auto Release

on:
  schedule:
    # Runs at 00:00 UTC every Monday (cron format)
    - cron: '0 0 * * 1'
  workflow_dispatch:

permissions:
  contents: write
  pull-requests: read

jobs:
  auto-release:
    uses: apple/swift-temporal-sdk/.github/workflows/auto-release.yml@main

How it works

The workflow automatically creates releases by:

  1. Analyzing PR labels since the last release
  2. Calculating the next version based on semantic versioning labels
  3. Creating a GitHub release with auto-generated release notes

Semantic versioning labels

Each PR should have one of these labels:

LabelDescriptionExample
semver/noneNo release needed (e.g., documentation updates, test improvements, CI changes)N/A
๐Ÿ”จ semver/patchPatch release for bug fixes with no public API changes0.0.1 โ†’ 0.0.2
๐Ÿ†• semver/minorMinor release for new features that maintain backward compatibility0.0.1 โ†’ 0.1.0
โš ๏ธ semver/majorMajor release for breaking changes (must be created manually)0.0.1 โ†’ 1.0.0

When a PR is merged, the automation will:

  1. Analyze all merged PRs since the last release
  2. Calculate the version bump based on the highest semver impact
  3. Automatically create a GitHub release with the newly calculated semantic version tag and generated release notes

Note: The first release and all major releases must be created manually by maintainers.

Requirements

Before using this workflow, your repository must have:

  1. At least one existing release - The workflow calculates new versions based on the last release
  2. Properly configured semver labels - PRs must be labeled with one of: semver/none, ๐Ÿ”จ semver/patch, ๐Ÿ†• semver/minor, or โš ๏ธ semver/major
  3. .github/release.yml file - Required for auto-generating release notes. See GitHub's documentation for configuration details
  4. Semver label validation - Integrate the NIO-provided semver-label-check action to ensure all PRs have appropriate labels
  5. A main branch - The workflow expects releases to be based on the main branch