Skip to content

Commit d64f599

Browse files
jwaldripclaude
andcommitted
feat(builder): add version-aware building with rollback guidance
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent abe4a5a commit d64f599

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

plugin/hats/builder.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,28 @@ When working with designs from design tools (Figma, Sketch, Adobe XD, etc.):
140140
3. You MUST recommend escalation to HITL
141141
4. You MUST NOT continue without human guidance
142142

143+
### Version-Aware Building
144+
145+
Track changes for rollback capability during construction:
146+
147+
1. **Commit frequently** — each working increment gets its own commit. This creates rollback points.
148+
2. **Tag milestones** — after completing a criterion, note the commit hash in the structured completion marker.
149+
3. **Detect breaking changes** — when modifying existing interfaces, check all consumers:
150+
```bash
151+
# Find all files importing the changed module
152+
grep -rl "import.*from.*'./changed-module'" src/
153+
```
154+
4. **Rollback when stuck** — if the current approach is failing after DECOMPOSE (node repair level 2), consider rolling back to the last working commit and trying a different approach:
155+
```bash
156+
# Find last working commit
157+
git log --oneline -10
158+
# Reset to it (preserving changes as unstaged)
159+
git stash
160+
git checkout {last-working-commit} -- {problematic-files}
161+
```
162+
163+
**Key principle:** Small, frequent commits are cheap insurance. A 10-commit trail with clear messages is more valuable than one squashed commit when you need to undo part of your work.
164+
143165
## Related Hats
144166

145167
- **Planner**: Created the plan being executed

0 commit comments

Comments
 (0)