# Yaba 2.0.0 Release Plan

## Target

- Package: `yaba-release-cli`
- Version: `2.0.0`
- Release type: major
- Date prepared: `2026-03-05`

## Why 2.0.0

This release combines CLI contract changes and automation-facing improvements that justify a major version:

- New command model: `release create`, `release preview`, `doctor`, `config init`
- Deterministic non-zero exit codes for failure classes
- JSON output mode for machine consumers
- Config-file support with precedence across flags/env/config/defaults

## Included Capability Set

- Release create command model and improved flag handling
- Release preview command (no side effects)
- First-release fallback handling (no prior tag)
- Default branch resolution from GitHub API metadata
- Repository detection from `remote.origin.url`
- Slack payload JSON safety hardening
- Deterministic exit-code mapping
- JSON output mode (`--format json`)
- Diagnostics command (`doctor`)
- Config template command (`config init --force`)
- Runtime config loading and precedence (`--config`, user/project config)

## Upgrade Notes (from 1.x)

- Prefer explicit command invocation: `yaba release create`
- Prefer `--publish` for Slack announcements
- Use `--no-prompt` in non-interactive automation
- For CI integrations, consume documented exit codes and/or `--format json`
- Keep secrets in env vars (`YABA_GITHUB_ACCESS_TOKEN`, `YABA_SLACK_HOOK_URL`)

## Release Checklist

1. Validate local tree and expected diff:
   - `package.json` version is `2.0.0`
   - `package-lock.json` version is `2.0.0`
2. Run validation:
   - `npm ci`
   - `npm test` (or project validation script once defined)
   - `node --check bin/index.js`
3. Smoke test core paths:
   - `yaba release preview --repo <repo>`
   - `yaba doctor`
   - `yaba config init --force`
   - `yaba release preview --repo <repo> --format json`
4. Cut release commit and tag:
   - commit: `chore(release): 2.0.0`
   - tag: `v2.0.0`
5. Publish:
   - `npm publish`
   - create GitHub release with this summary
6. Post-release verification:
   - install from npm in clean environment
   - run `yaba --version` and command smoke checks

## Rollback Plan

If issues are found post-release:

1. Deprecate broken npm artifact/version if needed.
2. Ship `2.0.1` hotfix from the release branch.
3. Publish incident notes with migration/workaround guidance.
