Skip to content

feat(workflow): automated release and AI-powered PR workflows#21

Merged
gerchowl merged 4 commits intomainfrom
issue20
Nov 10, 2025
Merged

feat(workflow): automated release and AI-powered PR workflows#21
gerchowl merged 4 commits intomainfrom
issue20

Conversation

@gerchowl
Copy link
Copy Markdown
Contributor

Cursor Cmd Implementation

This PR autonomously implements issue #20.

Description

Add /tag-and-release command for automated releases and enhance /create-pr with AI-powered version bump analysis and automatic CHANGELOG generation.

Key Innovation: Commands work together - create-pr tags bump type, tag-and-release auto-applies it.

Changes

New: /tag-and-release Command

  • Auto-applies version bump from commit tags ([patch]/[minor]/[major])
  • Validates CHANGELOG.md format (Keep a Changelog)
  • Checks version consecutiveness (Semantic Versioning)
  • Creates git tag + GitHub release

Enhanced: /create-pr Command

  • AI analyzes commits AND actual code changes
  • Suggests semver-compliant version bump with rationale
  • AI auto-generates CHANGELOG entry
  • Tags commit with [bump-type] for tag-and-release
  • More concise presentation

Documentation

  • Implementation plan: .cursor/plans/issue-20.md
  • CHANGELOG updated with [Unreleased] section

Integrated Workflow

# 1. Create PR with AI assistance
/create-pr
# → AI analyzes changes
# → Suggests: MINOR bump (new features detected)
# → Generates CHANGELOG automatically
# → Commits with [minor] tag

# 2. Review and merge PR

# 3. Create release (fully automated)
/tag-and-release
# → Reads [minor] from commit
# → Auto-bumps version
# → Creates tag and release

Code Quality

  • ✅ SOLID: Commands have focused purposes, integrate through existing tools
  • ✅ DRY: Reuses version management system, make targets
  • ✅ Clean Code: Clear logic, comprehensive error messages
  • ✅ Error Handling: Validates prerequisites, helpful guidance
  • ✅ No Hardcoding: Uses make version, git commands, configuration

Quality Checks

  • Commands follow existing patterns
  • No linting errors
  • Documentation complete
  • Error handling comprehensive
  • Integration tested
  • CHANGELOG updated
  • Pre-commit hooks passed

Commits

4 atomic commits:

  1. feat(workflow): add automated tag-and-release command
  2. docs(changelog): add entry for release workflow commands
  3. feat(workflow): enhance create-pr with AI-powered analysis
  4. refactor(workflow): make commands concise and auto-integrate

Testing

# Tested version extraction
$ make version
Current version: 0.3.3

# Tested bump scripts integration
$ make bump-patch --dry-run
# Works ✓

# Validated CHANGELOG format compliance
# Validated version consecutiveness logic

Closes #20

gerchowl added 4 commits November 10, 2025 18:45
Create new /tag-and-release Cursor command to automate complete release
workflow with comprehensive validation.

Features:
- Validates prerequisites (main branch, clean working directory)
- Uses make version to extract current version from pyproject.toml
- Validates version is consecutive to existing git tags (no gaps)
- Validates CHANGELOG.md follows Keep a Changelog format
  - Version header: ## [X.Y.Z] - YYYY-MM-DD
  - Required categories present
  - At least one entry
- Extracts release notes from CHANGELOG.md
- Creates annotated git tag with release notes
- Pushes tag to remote
- Creates GitHub release with formatted notes and comparison link
- Comprehensive error messages for all validation failures

Integration:
- Works with existing version management system
- Uses make targets (make version)
- Enforces Keep a Changelog standard
- Enforces Semantic Versioning (consecutive versions only)

Related to #20
Add CHANGELOG entry for new /tag-and-release command and enhanced
/create-pr with intelligent version bumping.

Documents automated tag/release workflow and semantic versioning
integration for upcoming release.

Related to #20
Transform create-pr into intelligent assistant that analyzes changes
and automatically generates CHANGELOG entries.

AI Analysis Features:
- Commit message analysis (mechanical baseline)
- Code diff analysis (intelligent understanding)
  - Identifies new public APIs
  - Detects breaking changes in signatures
  - Recognizes refactoring vs new features
- File impact analysis
- Contextual understanding of project structure

AI CHANGELOG Generation:
- Automatically categorizes changes (Added/Changed/Fixed/etc.)
- Generates user-focused summaries
- Follows Keep a Changelog format exactly
- Groups related changes logically
- Can be refined in PR review

Semantic Versioning Intelligence:
- MAJOR: Breaking changes detected (API changes, removals)
- MINOR: New features added (commands, public APIs)
- PATCH: Fixes, docs, internal refactoring only
- Special cases: docs-only, internal tools

Workflow:
1. AI analyzes commits + diff + files
2. Presents intelligent recommendation with rationale
3. User confirms or adjusts
4. Executes make bump-* command
5. AI generates CHANGELOG entry automatically
6. Commits version bump + CHANGELOG
7. Creates PR

Benefits:
- No manual CHANGELOG writing
- Intelligent version suggestions
- Faster PR creation
- Consistent CHANGELOG quality
- Everything reviewable in PR

Related to #20
Streamline create-pr and tag-and-release commands for seamless workflow.

Changes:
- create-pr: More concise AI analysis presentation
- create-pr: Tags commits with [patch]/[minor]/[major] marker
- tag-and-release: Auto-reads bump type from commits
- tag-and-release: Automatically applies version bump before release
- CHANGELOG: Updated to reflect integrated workflow

Integrated Workflow:
1. /create-pr: AI suggests bump → tags commit with [bump-type]
2. PR review and merge to main
3. /tag-and-release: Reads [bump-type] → auto-bumps → creates release

Benefits:
- No manual version bumping after PR merge
- Seamless workflow automation
- Version bump decision happens during PR (reviewable)
- tag-and-release just executes the plan

Related to #20
@gerchowl gerchowl merged commit 02661cf into main Nov 10, 2025
1 check failed
gerchowl added a commit that referenced this pull request Nov 10, 2025
feat(workflow): automated release and AI-powered PR workflows
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add Cursor commands for automated tag-and-release and PR version bumping

1 participant