--- allowed-tools: Bash(git tag:*), Bash(git add:*), Bash(git commit:*), Bash(git push:*), Bash(git log:*), Bash(git describe:*), Bash(git-cliff:*), Bash(git cliff:*) description: Create a new semver release. Usage: /release-new [major|minor|patch] --- ## Context - Current latest tag: !`git describe --tags --abbrev=0 2>/dev/null || echo "none"` - Current branch: !`git branch --show-current` - Unreleased commits: !`git log --oneline -20` ## Your task Arguments: $ARGUMENTS (should be "major", "minor", or "patch") 1. **Determine next version**: - Get current latest tag (from context above). If none, start at v0.1.0. - Parse the version as vMAJOR.MINOR.PATCH. - Bump the appropriate component based on arguments (default: patch if none given). - New version = vX.Y.Z (with "v" prefix). 2. **Update CHANGELOG.md** using git-cliff: ``` git-cliff --config cliff.toml --tag NEW_VERSION -o CHANGELOG.md ``` 3. **Commit the changelog**: - Stage: `git add CHANGELOG.md` - Commit: `git commit -m "chore: release NEW_VERSION"` 4. **Create annotated tag**: ``` git tag -a NEW_VERSION -m "Release NEW_VERSION" ``` 5. **Push commit and tag**: ``` git push && git push --tags ``` Do not ask for confirmation. Execute all steps in sequence. Report what version was released when done.