Files
payload-mailing/.github/workflows/version-and-publish.yml
Bas van den Aakster e0dad848fc Restructure workflow to use merge PRs for release preparation
### 🚀 Features
- Push to version branches (major/*, minor/*, patch/*) now creates merge PRs
- Merge branches (merge/major-*, merge/minor-*, merge/patch-*) contain prepared releases
- Version bump, changelog generation, and validation happen before merge
- Release publishing only occurs after merge PR approval

### 🔧 Improvements
- Separated release preparation from publishing for better review workflow
- Added automatic PR creation/updating for release branches
- Streamlined publishing job that uses pre-prepared version and changelog
- Clear PR descriptions with release checklist and warnings

### 🐛 Bug Fixes
- Fixed workflow timing to allow proper review before publishing
- Eliminated race conditions between version preparation and publishing
- Improved error handling and validation throughout the process

**Workflow Structure:**
1. Push to `patch/feature-name` → Creates/updates `merge/patch-feature-name` → Opens PR to main
2. Review and approve merge PR (version already bumped, changelog included)
3. Merge PR to main → Automatically publishes to NPM and creates GitHub release

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-09-13 13:58:19 +02:00

14 KiB