Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,19 +1,38 @@
name: Release
name: Release Please

on:
push:
tags:
- "v*"
branches: [main]

permissions:
contents: write # required for gh release create
contents: write
pull-requests: write
issues: write

jobs:
release:
release-please:
name: release-please
runs-on: ubuntu-latest
outputs:
release_created: ${{ steps.release.outputs.release_created }}
tag_name: ${{ steps.release.outputs.tag_name }}
steps:
- uses: googleapis/release-please-action@v4
id: release
with:
token: ${{ secrets.GITHUB_TOKEN }}
config-file: release-please-config.json
manifest-file: .release-please-manifest.json

build:
name: build and publish (windows / py3.12)
needs: release-please
if: ${{ needs.release-please.outputs.release_created == 'true' }}
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
with:
ref: ${{ needs.release-please.outputs.tag_name }}

- uses: actions/setup-python@v5
with:
Expand All @@ -25,7 +44,7 @@ jobs:
python -m pip install --upgrade pip
pip install -r requirements.txt -r requirements-build.txt

# Gate the release on the same test suite CI runs — never ship a broken build.
# Gate the published build on the same test suite CI runs.
- name: Run tests
env:
QT_QPA_PLATFORM: offscreen
Expand All @@ -34,31 +53,21 @@ jobs:
- name: Build executable
run: python -m PyInstaller --noconfirm --clean screamer.spec

# screamer.spec uses COLLECT (onedir), so the artifact is the dist\Screamer
# folder zipped whole — users extract it and run Screamer\Screamer.exe.
# screamer.spec uses COLLECT (onedir): zip the whole dist\Screamer folder.
- name: Package
shell: pwsh
run: |
$tag = $env:GITHUB_REF_NAME
$tag = "${{ needs.release-please.outputs.tag_name }}"
$zip = "Screamer-$tag-windows-x64.zip"
Compress-Archive -Path dist\Screamer -DestinationPath $zip
$hash = (Get-FileHash $zip -Algorithm SHA256).Hash.ToLower()
"$hash $zip" | Out-File -FilePath "$zip.sha256" -Encoding ascii
"ASSET_ZIP=$zip" | Out-File -FilePath $env:GITHUB_ENV -Append
"ASSET_SHA=$zip.sha256" | Out-File -FilePath $env:GITHUB_ENV -Append

# Hyphenated tags (v1.0.0-rc1, v1.2.0-beta) publish as pre-releases.
- name: Publish release
# Attach the build to the release that release-please already created.
- name: Upload assets to release
env:
GH_TOKEN: ${{ github.token }}
shell: pwsh
run: |
$tag = $env:GITHUB_REF_NAME
$ghArgs = @(
"release", "create", $tag,
$env:ASSET_ZIP, $env:ASSET_SHA,
"--title", $tag,
"--generate-notes"
)
if ($tag -match "-") { $ghArgs += "--prerelease" }
& gh @ghArgs
run: gh release upload "${{ needs.release-please.outputs.tag_name }}" $env:ASSET_ZIP $env:ASSET_SHA --clobber
3 changes: 3 additions & 0 deletions .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
".": "1.0.1"
}
22 changes: 7 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -157,26 +157,18 @@ python -m PyInstaller --noconfirm --clean screamer.spec

## Releases

Pushing a version tag builds and publishes a Windows release automatically:
Releases are automated with [Release Please](https://github.com/googleapis/release-please) from [Conventional Commits](https://www.conventionalcommits.org/).

```bash
git tag v1.0.0
git push origin v1.0.0
```

The release workflow:

1. Installs dependencies.
2. Runs the test suite.
3. Builds Screamer with PyInstaller.
4. Packages the app as:
1. Merging commits to `main` keeps a **Release PR** up to date — it bumps the version and updates `CHANGELOG.md`.
2. Merging that Release PR tags the version (`vX.Y.Z`) and publishes a GitHub Release with generated notes.
3. A Windows build job then runs the test suite, builds with PyInstaller, and attaches the packaged app:

```text
Screamer-v1.0.0-windows-x64.zip
Screamer-v1.0.0-windows-x64.zip.sha256
Screamer-vX.Y.Z-windows-x64.zip
Screamer-vX.Y.Z-windows-x64.zip.sha256
```

Hyphenated tags like `v1.0.0-rc1` are published as pre-releases.
Version bumps follow the commit types: `fix:` → patch, `feat:` → minor, and `feat!:` / `BREAKING CHANGE:` → major.

## Platform

Expand Down
5 changes: 5 additions & 0 deletions docs/RELEASE_PIPELINE_PLAN.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# Plan — GitHub Release Pipeline

> **Superseded (2026-06):** This tag-triggered `release.yml` pipeline has been replaced by
> [Release Please](https://github.com/googleapis/release-please). The build/publish steps now live in
> `.github/workflows/release-please.yml` (run on release creation), and `release.yml` has been removed.
> See `docs/superpowers/plans/2026-06-04-release-please.md`. Kept below for historical context.

## Goal
On a version tag push, automatically build the Windows `.exe`, package it, and publish a GitHub Release with the artifact attached. No manual build/upload steps.

Expand Down
Loading
Loading