From 969aef41d12ee5c2494761e2c37d068ffd5c2053 Mon Sep 17 00:00:00 2001 From: Garry Tan Date: Sat, 28 Mar 2026 22:35:39 -0700 Subject: [PATCH] feat: add feature signal detection to version bump heuristic (#573) /ship Step 4 now checks for feature signals (new routes, migrations, test+source pairs, feat/ branches) when deciding version bumps. PATCH requires no feature signals. MINOR asks the user if any signal is detected or 500+ lines changed. Co-Authored-By: Claude Opus 4.6 (1M context) --- ship/SKILL.md | 5 +++-- ship/SKILL.md.tmpl | 5 +++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/ship/SKILL.md b/ship/SKILL.md index dab72f69..fd48cec9 100644 --- a/ship/SKILL.md +++ b/ship/SKILL.md @@ -1611,9 +1611,10 @@ High-confidence findings (agreed on by multiple sources) should be prioritized f 2. **Auto-decide the bump level based on the diff:** - Count lines changed (`git diff origin/...HEAD --stat | tail -1`) + - Check for feature signals: new route/page files (e.g. `app/*/page.tsx`, `pages/*.ts`), new DB migration/schema files, new test files alongside new source files, or branch name starting with `feat/` - **MICRO** (4th digit): < 50 lines changed, trivial tweaks, typos, config - - **PATCH** (3rd digit): 50+ lines changed, bug fixes, small-medium features - - **MINOR** (2nd digit): **ASK the user** — only for major features or significant architectural changes + - **PATCH** (3rd digit): 50+ lines changed, no feature signals detected + - **MINOR** (2nd digit): **ASK the user** if ANY feature signal is detected, OR 500+ lines changed, OR new modules/packages added - **MAJOR** (1st digit): **ASK the user** — only for milestones or breaking changes 3. Compute the new version: diff --git a/ship/SKILL.md.tmpl b/ship/SKILL.md.tmpl index 3ea14072..691d520f 100644 --- a/ship/SKILL.md.tmpl +++ b/ship/SKILL.md.tmpl @@ -324,9 +324,10 @@ For each classified comment: 2. **Auto-decide the bump level based on the diff:** - Count lines changed (`git diff origin/...HEAD --stat | tail -1`) + - Check for feature signals: new route/page files (e.g. `app/*/page.tsx`, `pages/*.ts`), new DB migration/schema files, new test files alongside new source files, or branch name starting with `feat/` - **MICRO** (4th digit): < 50 lines changed, trivial tweaks, typos, config - - **PATCH** (3rd digit): 50+ lines changed, bug fixes, small-medium features - - **MINOR** (2nd digit): **ASK the user** — only for major features or significant architectural changes + - **PATCH** (3rd digit): 50+ lines changed, no feature signals detected + - **MINOR** (2nd digit): **ASK the user** if ANY feature signal is detected, OR 500+ lines changed, OR new modules/packages added - **MAJOR** (1st digit): **ASK the user** — only for milestones or breaking changes 3. Compute the new version: