| name | Deployment Safety |
| description | Production deployment rules, rollback-first recovery, dependency batching, CI cost awareness, and framework upgrade verification. |
Deployment Safety
Merging to Main
Wrong -- merge Dependabot PR thinking it's cleanup:
gh pr merge 42 --merge
Right -- move the update onto the non-production integration path,
close the PR, and release normally:
git checkout develop && git cherry-pick <commit>
gh pr close 42
git checkout -b chore/dependency-updates main
git cherry-pick <commit>
gh pr close 42
Dependency Batching
Wrong -- merge N PRs one-by-one (O(n^2) rebase cascade):
gh pr merge 1 && gh pr merge 2 && gh pr merge 3
Right -- batch into a single branch:
git checkout -b chore/dependency-updates develop
git checkout -b chore/dependency-updates main
CI Cost Awareness
Wrong -- push partial work to see if CI passes:
git push
Right -- test locally, push once:
pnpm run typecheck 2>&1; pnpm run lint 2>&1; pnpm run test 2>&1
git push
Framework Upgrades
Wrong -- merge after CI passes (CI != production):
gh pr merge 99 --squash
Right -- verify on preview deployment first:
Production Incident Recovery
Wrong -- deploy fixes to prod while investigating:
vercel deploy --prod
Right -- roll back first, investigate second:
vercel rollback
Justify Every Action
Before any CI run, deployment, or API call:
1. Is this needed? (Can I achieve this locally?)
2. Is this justified? (Does this advance the task?)
3. Is this verifiable? (Will I know if it succeeded?)
If any answer is "no" -- do not proceed.