spark-release
Create a new git tag and a GitHub release (with the GitHub generated notes), then update the CHANGELOG.md
SKILL.md.claude/skills/spark-release/SKILL.md
GitHubSpark Release Skill
Overview
This skill creates a new version of Spark iOS:
- Updates the
CHANGELOG.mdwith the.script/update-changelog.swiftscript and thespark-changelogskill, then pushes it onmain. - Creates the git tag (on the changelog commit) and the GitHub release with the notes generated by GitHub.
Prerequisites
ghmust be installed and authenticated (gh auth status). If not, stop and tell the user to run! gh auth login.- The current branch must be
mainand up to date withorigin/main(git fetch origin --tagsthengit status). If not, stop and ask the user. - The working tree must be clean.
- Do not mention Claude.
Steps
- Get the latest tag:
git fetch origin --tagsthengit tag --sort=-v:refname | head -1(e.g.2.2.1). - Ask the user the new version (semantic versioning
X.Y.Z, novprefix). Propose the patch, minor and major bumps of the latest tag (e.g.2.2.2,2.3.0,3.0.0). Check the tag does not already exist. - Generate the default release notes from GitHub:
The expected content looks like:gh api repos/leboncoin/spark-ios/releases/generate-notes \ -f tag_name=<new-version> \ -f target_commitish=main \ -f previous_tag_name=<latest-tag> \ --jq .body## What's Changed * fix(button): include padding in UIKit button intrinsic content size by @robergro in https://github.com/leboncoin/spark-ios/pull/1128 **Full Changelog**: https://github.com/leboncoin/spark-ios/compare/2.2.0...2.2.1 - Propose a release title:
<new-version> - <summary>, where<summary>is a short lowercase sentence (no final period) describing the main changes of the release. Examples:2.2.1 - include padding in UIKit button intrinsic content size2.2.0 - drop iOS 16 support and set iOS 17 as minimum deployment target2.1.0 - improve segmented control and spinner, update documentationCheck the previous titles withgh release list -L 5to keep the same style.
- Show the version, the release title and the release notes to the user and ask for confirmation before going further.
- Update the changelog first (it must be in the released commit), staying on
main:- Run the script from the repository root:
swift .script/update-changelog.swift <new-version> "<release notes>". - Use the
spark-changelogskill to replace the placeholder with the real content. - Once the changelog is validated, use the
spark-pushskill to commit (chore(changelog): update for <new-version>) and push directly onmain(do not create a branch for this commit).
- Run the script from the repository root:
- Ask for confirmation before creating the tag and the release (they are public).
- Create and push the tag on the changelog commit:
git tag <new-version> git push origin <new-version> - Create the GitHub release with the generated notes (pass them through a temporary file to keep the formatting):
gh release create <new-version> --title "<release-title>" --notes-file <notes-file> --verify-tag --latest - Show the release URL to the user.
Notes
- If the tag push or the release creation fails, do not retry blindly: show the error to the user. If the tag was pushed but the release failed, only retry the
gh release createstep. - Never delete or move an existing tag without an explicit request of the user.