jettypod 4.4.95 β 4.4.97
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/git-hooks/post-merge +1 -1
- package/package.json +1 -1
- package/skills-templates/chore-mode/SKILL.md +44 -0
- package/skills-templates/feature-planning/SKILL.md +209 -183
- package/skills-templates/production-mode/SKILL.md +96 -0
- package/skills-templates/speed-mode/SKILL.md +58 -0
- package/skills-templates/stable-mode/SKILL.md +58 -0
package/lib/git-hooks/post-merge
CHANGED
|
@@ -57,7 +57,7 @@ const currentWork = JSON.parse(fs.readFileSync(currentWorkPath, 'utf-8'));
|
|
|
57
57
|
// Update to done using shared updateStatus (includes epic auto-close logic)
|
|
58
58
|
(async () => {
|
|
59
59
|
try {
|
|
60
|
-
const { updateStatus } = require('__JETTYPOD_ROOT__/
|
|
60
|
+
const { updateStatus } = require('__JETTYPOD_ROOT__/lib/work-tracking');
|
|
61
61
|
await updateStatus(currentWork.id, 'done');
|
|
62
62
|
|
|
63
63
|
// Clear current work pointer since work is done
|
package/package.json
CHANGED
|
@@ -67,6 +67,14 @@ Your shell's working directory was likely inside a worktree that was deleted. Th
|
|
|
67
67
|
|
|
68
68
|
**Your task:** Acknowledge the context passed from chore-planning.
|
|
69
69
|
|
|
70
|
+
**π« FORBIDDEN: Writing Files at This Step**
|
|
71
|
+
```
|
|
72
|
+
β Write tool to any path
|
|
73
|
+
β Edit tool to any path
|
|
74
|
+
β Any file creation or modification
|
|
75
|
+
```
|
|
76
|
+
**This is a CONTEXT step.** File writes happen in Step 5.
|
|
77
|
+
|
|
70
78
|
You will receive:
|
|
71
79
|
- `choreContext.chore` - Chore ID, title, description
|
|
72
80
|
- `choreContext.classification` - Type and confidence
|
|
@@ -149,10 +157,34 @@ Resolve the issue before continuing.
|
|
|
149
157
|
|
|
150
158
|
**Move to Step 3 only if worktree was created successfully.**
|
|
151
159
|
|
|
160
|
+
**π WORKTREE PATH LOCK**
|
|
161
|
+
|
|
162
|
+
After worktree validation passes, capture and lock the path:
|
|
163
|
+
- `WORKTREE_PATH` - the absolute path from the query result
|
|
164
|
+
|
|
165
|
+
**Display:**
|
|
166
|
+
|
|
167
|
+
```
|
|
168
|
+
π WORKTREE LOCK ACTIVE
|
|
169
|
+
Path: ${WORKTREE_PATH}
|
|
170
|
+
|
|
171
|
+
All file writes will use this path.
|
|
172
|
+
```
|
|
173
|
+
|
|
174
|
+
**From this point forward, ALL file operations MUST use paths starting with `${WORKTREE_PATH}/`**
|
|
175
|
+
|
|
152
176
|
### Step 3: Establish Test Baseline
|
|
153
177
|
|
|
154
178
|
**Your task:** Run tests to establish baseline before making changes.
|
|
155
179
|
|
|
180
|
+
**π« FORBIDDEN: Writing Files at This Step**
|
|
181
|
+
```
|
|
182
|
+
β Write tool to any path
|
|
183
|
+
β Edit tool to any path
|
|
184
|
+
β Any file creation or modification
|
|
185
|
+
```
|
|
186
|
+
**This is a TESTING step.** File writes happen in Step 5.
|
|
187
|
+
|
|
156
188
|
**Test handling varies by type:**
|
|
157
189
|
|
|
158
190
|
**For REFACTOR:**
|
|
@@ -205,6 +237,14 @@ jettypod workflow checkpoint <chore-id> --step=3
|
|
|
205
237
|
|
|
206
238
|
**Your task:** Display warnings and constraints based on chore type.
|
|
207
239
|
|
|
240
|
+
**π« FORBIDDEN: Writing Files at This Step**
|
|
241
|
+
```
|
|
242
|
+
β Write tool to any path
|
|
243
|
+
β Edit tool to any path
|
|
244
|
+
β Any file creation or modification
|
|
245
|
+
```
|
|
246
|
+
**This is a GUIDANCE step.** File writes happen in Step 5.
|
|
247
|
+
|
|
208
248
|
**Load guidance from taxonomy:**
|
|
209
249
|
|
|
210
250
|
```javascript
|
|
@@ -258,6 +298,10 @@ const guidance = getGuidance('[chore-type]');
|
|
|
258
298
|
|
|
259
299
|
### Step 5: Execute with Iteration
|
|
260
300
|
|
|
301
|
+
**π WORKTREE PATH REQUIRED:** All file writes MUST use the `WORKTREE_PATH` captured in Step 2.
|
|
302
|
+
|
|
303
|
+
**β
NOW you may write files** - worktree is locked, guidance is displayed.
|
|
304
|
+
|
|
261
305
|
**Your task:** Make changes and iterate until tests pass. Max 5 iterations.
|
|
262
306
|
|
|
263
307
|
```
|
|
@@ -17,19 +17,20 @@ When this skill is activated, you are helping discover the best approach for a f
|
|
|
17
17
|
|
|
18
18
|
| Command | Used For | When | Phase |
|
|
19
19
|
|---------|----------|------|-------|
|
|
20
|
-
| `work
|
|
21
|
-
| `work tests
|
|
22
|
-
| `work
|
|
23
|
-
| `work start <chore-id>` | Start implementing a specific chore | After tests merged (Step
|
|
20
|
+
| `work tests start <feature-id>` | Create worktree for test authoring | After Integration Contract (Step 7) | Feature Planning |
|
|
21
|
+
| `work tests merge` β `cd` β `work cleanup` | Merge tests to main, then cleanup worktree | After chores created (Step 12) | Feature Planning |
|
|
22
|
+
| `work implement <feature-id>` | Transition feature to implementation phase | After chores created (Step 11) | Feature Planning |
|
|
23
|
+
| `work start <chore-id>` | Start implementing a specific chore | After tests merged (Step 13) | Speed Mode |
|
|
24
24
|
|
|
25
25
|
**CRITICAL:** All commands are run by **Claude**, not the user. The distinction is:
|
|
26
|
+
- `work tests start` = Creates isolated worktree for BDD test authoring (Step 7)
|
|
26
27
|
- `work implement` = Ends feature planning, transitions to implementation phase
|
|
27
|
-
- `work tests
|
|
28
|
+
- `work tests merge` = Land BDD tests on main
|
|
28
29
|
- `work start` = Creates worktree/branch for chore implementation
|
|
29
30
|
|
|
30
|
-
**π STOP GATE:** DO NOT run `work start` until Step
|
|
31
|
+
**π STOP GATE:** DO NOT run `work start` until Step 13. Tests must be merged to main first.
|
|
31
32
|
|
|
32
|
-
**π HANDOFF REQUIREMENT:** After `work start`, you MUST invoke speed-mode using the Skill tool. See Step
|
|
33
|
+
**π HANDOFF REQUIREMENT:** After `work start`, you MUST invoke speed-mode using the Skill tool. See Step 13.
|
|
33
34
|
|
|
34
35
|
---
|
|
35
36
|
|
|
@@ -228,7 +229,7 @@ Which approach works best?
|
|
|
228
229
|
|
|
229
230
|
**WAIT for user response.**
|
|
230
231
|
|
|
231
|
-
User picks winner. Note their choice - you'll record it formally in Step
|
|
232
|
+
User picks winner. Note their choice - you'll record it formally in Step 11 when transitioning to implementation.
|
|
232
233
|
|
|
233
234
|
**π WORKFLOW CHECKPOINT: Winner chosen**
|
|
234
235
|
|
|
@@ -238,12 +239,10 @@ jettypod workflow checkpoint <feature-id> --step=5
|
|
|
238
239
|
|
|
239
240
|
**Proceed to Step 6.**
|
|
240
241
|
|
|
241
|
-
### Step 6: Define Integration Contract
|
|
242
|
+
### Step 6: Define Integration Contract
|
|
242
243
|
|
|
243
244
|
**CRITICAL:** Before writing scenarios, you MUST define how users reach this feature. Features that pass tests but aren't integrated into the product are useless.
|
|
244
245
|
|
|
245
|
-
#### Step 6A: Define Integration Contract
|
|
246
|
-
|
|
247
246
|
**Ask yourself and document:**
|
|
248
247
|
|
|
249
248
|
1. **Entry Point** - How does a user reach this feature?
|
|
@@ -279,17 +278,77 @@ Example:
|
|
|
279
278
|
|
|
280
279
|
**WAIT for user to confirm or adjust the integration contract.**
|
|
281
280
|
|
|
282
|
-
|
|
281
|
+
**Proceed to Step 7.**
|
|
282
|
+
|
|
283
|
+
### Step 7: Create Test Worktree
|
|
284
|
+
|
|
285
|
+
**CRITICAL:** Create the isolated worktree BEFORE proposing scenarios. This ensures:
|
|
286
|
+
1. A safe workspace exists before any file discussion
|
|
287
|
+
2. Claude has `WORKTREE_PATH` before being tempted to write files
|
|
288
|
+
3. Writing to main is impossible because we're in worktree context
|
|
289
|
+
|
|
290
|
+
**π« FORBIDDEN: Manual Git Worktree Commands**
|
|
291
|
+
```
|
|
292
|
+
β git worktree add ...
|
|
293
|
+
β git checkout -b tests/...
|
|
294
|
+
β git branch tests/...
|
|
295
|
+
```
|
|
296
|
+
**ALWAYS use jettypod commands** - they handle branch naming, path conventions, database tracking, and cleanup. Manual git commands will create orphaned worktrees that break the merge workflow.
|
|
297
|
+
|
|
298
|
+
**Run:**
|
|
299
|
+
|
|
300
|
+
```bash
|
|
301
|
+
jettypod work tests start ${FEATURE_ID}
|
|
302
|
+
```
|
|
303
|
+
|
|
304
|
+
This creates:
|
|
305
|
+
- Worktree at `.jettypod-work/tests-<id>-<slug>/`
|
|
306
|
+
- Branch `tests/feature-<id>-<slug>`
|
|
307
|
+
|
|
308
|
+
**π STOP AND CHECK:** Verify worktree was created successfully. If you see an error, investigate before continuing.
|
|
309
|
+
|
|
310
|
+
**Capture from output:**
|
|
311
|
+
- `WORKTREE_PATH` - the absolute path to the worktree (e.g., `/path/to/.jettypod-work/tests-42-email-login`)
|
|
312
|
+
|
|
313
|
+
Example output:
|
|
314
|
+
```
|
|
315
|
+
β
Created test worktree: /path/to/.jettypod-work/tests-42-email-login
|
|
316
|
+
Branch: tests/feature-42-email-login
|
|
317
|
+
|
|
318
|
+
Write your BDD files to:
|
|
319
|
+
<worktree>/features/email-login.feature
|
|
320
|
+
<worktree>/features/step_definitions/email-login.steps.js
|
|
321
|
+
```
|
|
322
|
+
|
|
323
|
+
**Display:**
|
|
283
324
|
|
|
284
|
-
**π« FORBIDDEN: Writing Files at This Step**
|
|
285
325
|
```
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
326
|
+
π Test worktree created: ${WORKTREE_PATH}
|
|
327
|
+
Branch: tests/feature-${FEATURE_ID}-${FEATURE_SLUG}
|
|
328
|
+
|
|
329
|
+
π WORKTREE LOCK ACTIVE: All BDD file writes will use this path.
|
|
289
330
|
```
|
|
290
|
-
**Files are written in Step 8D** inside an isolated worktree. At this step, you are ONLY displaying proposed scenarios to the user for confirmation. The worktree doesn't exist yet.
|
|
291
331
|
|
|
292
|
-
|
|
332
|
+
**π WORKTREE PATH LOCK**
|
|
333
|
+
|
|
334
|
+
From this point forward, ALL file operations for BDD tests MUST use paths starting with:
|
|
335
|
+
```
|
|
336
|
+
${WORKTREE_PATH}/features/
|
|
337
|
+
```
|
|
338
|
+
|
|
339
|
+
**Store `WORKTREE_PATH`** - you'll need it for Step 9.
|
|
340
|
+
|
|
341
|
+
**Proceed to Step 8.**
|
|
342
|
+
|
|
343
|
+
### Step 8: Propose BDD Scenarios
|
|
344
|
+
|
|
345
|
+
**π« FORBIDDEN: Writing Files at This Step**
|
|
346
|
+
```
|
|
347
|
+
β Write tool to ${WORKTREE_PATH}/features/*.feature
|
|
348
|
+
β Write tool to ${WORKTREE_PATH}/features/step_definitions/*.js
|
|
349
|
+
β Any file creation (even in worktree)
|
|
350
|
+
```
|
|
351
|
+
**Files are written in Step 9** after user confirms the scenarios. At this step, you are ONLY displaying proposed scenarios to the user for confirmation.
|
|
293
352
|
|
|
294
353
|
**Feature slug:** Derive `FEATURE_SLUG` from the feature title:
|
|
295
354
|
- Lowercase
|
|
@@ -302,8 +361,8 @@ Based on chosen approach, **display** the proposed scenarios to the user:
|
|
|
302
361
|
```
|
|
303
362
|
π Proposed BDD Scenarios
|
|
304
363
|
|
|
305
|
-
**Feature file:** features/[feature-slug].feature
|
|
306
|
-
**Step definitions:** features/step_definitions/[feature-slug].steps.js
|
|
364
|
+
**Feature file:** ${WORKTREE_PATH}/features/[feature-slug].feature
|
|
365
|
+
**Step definitions:** ${WORKTREE_PATH}/features/step_definitions/[feature-slug].steps.js
|
|
307
366
|
```
|
|
308
367
|
|
|
309
368
|
Then show the full Gherkin content:
|
|
@@ -316,8 +375,8 @@ Feature: [Feature Name]
|
|
|
316
375
|
Approach: [Chosen approach name]
|
|
317
376
|
|
|
318
377
|
# Integration Contract:
|
|
319
|
-
# Entry Point: [from Step
|
|
320
|
-
# Caller Code: [from Step
|
|
378
|
+
# Entry Point: [from Step 6]
|
|
379
|
+
# Caller Code: [from Step 6]
|
|
321
380
|
|
|
322
381
|
# INTEGRATION SCENARIO (REQUIRED - proves feature is reachable)
|
|
323
382
|
Scenario: User can reach [feature] from [entry point]
|
|
@@ -354,7 +413,7 @@ Does this capture the feature correctly? Any scenarios to add/change?
|
|
|
354
413
|
```
|
|
355
414
|
|
|
356
415
|
**Scenario content requirements:**
|
|
357
|
-
- **FIRST scenario MUST be the Integration Scenario** from Step
|
|
416
|
+
- **FIRST scenario MUST be the Integration Scenario** from Step 6 (proves reachability)
|
|
358
417
|
- **Include all "make it work" scenarios**:
|
|
359
418
|
- All success paths - required functionality AND optional features
|
|
360
419
|
- Multiple valid workflows if the feature supports them
|
|
@@ -365,17 +424,17 @@ Does this capture the feature correctly? Any scenarios to add/change?
|
|
|
365
424
|
|
|
366
425
|
**WAIT for user confirmation.**
|
|
367
426
|
|
|
368
|
-
- If user confirms β Proceed to Step
|
|
427
|
+
- If user confirms β Proceed to Step 9
|
|
369
428
|
- If user requests changes β Revise scenarios and display again
|
|
370
|
-
- **Store the confirmed scenarios in memory** - you'll write them in Step
|
|
429
|
+
- **Store the confirmed scenarios in memory** - you'll write them in Step 9
|
|
371
430
|
|
|
372
431
|
**π WORKFLOW CHECKPOINT: BDD scenarios confirmed**
|
|
373
432
|
|
|
374
433
|
```bash
|
|
375
|
-
jettypod workflow checkpoint <feature-id> --step=
|
|
434
|
+
jettypod workflow checkpoint <feature-id> --step=8
|
|
376
435
|
```
|
|
377
436
|
|
|
378
|
-
**Proceed to Step
|
|
437
|
+
**Proceed to Step 9.**
|
|
379
438
|
|
|
380
439
|
**Template for speed mode (make it work):**
|
|
381
440
|
|
|
@@ -387,8 +446,8 @@ Feature: [Feature Name]
|
|
|
387
446
|
Approach: [Chosen approach name]
|
|
388
447
|
|
|
389
448
|
# Integration Contract:
|
|
390
|
-
# Entry Point: [from Step
|
|
391
|
-
# Caller Code: [from Step
|
|
449
|
+
# Entry Point: [from Step 6]
|
|
450
|
+
# Caller Code: [from Step 6]
|
|
392
451
|
|
|
393
452
|
# INTEGRATION SCENARIO (REQUIRED - proves feature is reachable)
|
|
394
453
|
Scenario: User can reach [feature] from [entry point]
|
|
@@ -500,13 +559,94 @@ Scenario: Prevent unauthorized access
|
|
|
500
559
|
|
|
501
560
|
</details>
|
|
502
561
|
|
|
503
|
-
### Step
|
|
562
|
+
### Step 9: Write and Validate BDD Files
|
|
504
563
|
|
|
505
|
-
**
|
|
564
|
+
**NOW you may write files** - the worktree exists (from Step 7) and scenarios are confirmed (from Step 8).
|
|
565
|
+
|
|
566
|
+
**π WORKTREE PATH REQUIRED:** All file writes MUST use the `WORKTREE_PATH` captured in Step 7.
|
|
567
|
+
|
|
568
|
+
Using the scenarios confirmed in Step 8, write the files using **absolute paths to the worktree**:
|
|
569
|
+
|
|
570
|
+
**A. Write scenario file** using Write tool:
|
|
571
|
+
```
|
|
572
|
+
${WORKTREE_PATH}/features/${FEATURE_SLUG}.feature
|
|
573
|
+
```
|
|
574
|
+
|
|
575
|
+
**B. Write step definitions file** using Write tool:
|
|
576
|
+
```
|
|
577
|
+
${WORKTREE_PATH}/features/step_definitions/${FEATURE_SLUG}.steps.js
|
|
578
|
+
```
|
|
579
|
+
|
|
580
|
+
**Step definition requirements:**
|
|
581
|
+
1. Implement all Given/When/Then steps from the scenarios
|
|
582
|
+
2. Follow existing patterns - check other `.steps.js` files for conventions
|
|
583
|
+
3. Include test environment setup/cleanup
|
|
584
|
+
4. All Given steps (setup state)
|
|
585
|
+
5. All When steps (execute actions)
|
|
586
|
+
6. All Then steps (verify outcomes)
|
|
587
|
+
|
|
588
|
+
**Validate BDD infrastructure:**
|
|
589
|
+
|
|
590
|
+
Run cucumber dry-run **from within the worktree**:
|
|
591
|
+
|
|
592
|
+
```bash
|
|
593
|
+
cd ${WORKTREE_PATH} && npx cucumber-js --dry-run features/${FEATURE_SLUG}.feature
|
|
594
|
+
```
|
|
595
|
+
|
|
596
|
+
**What the output means:**
|
|
597
|
+
|
|
598
|
+
β
**Success** - No errors, all steps have definitions:
|
|
599
|
+
```
|
|
600
|
+
0 scenarios
|
|
601
|
+
0 steps
|
|
602
|
+
```
|
|
603
|
+
(Dry-run doesn't execute, so 0 is correct)
|
|
604
|
+
|
|
605
|
+
β **Undefined steps** - Missing step definitions:
|
|
606
|
+
```
|
|
607
|
+
Undefined. Implement with the following snippet:
|
|
608
|
+
Given('I am on the login page', function () {
|
|
609
|
+
...
|
|
610
|
+
});
|
|
611
|
+
```
|
|
612
|
+
β Add the missing step definition to your `.steps.js` file
|
|
613
|
+
|
|
614
|
+
β **Syntax error** - Invalid Gherkin:
|
|
615
|
+
```
|
|
616
|
+
Parse error in features/foo.feature
|
|
617
|
+
```
|
|
618
|
+
β Fix the feature file syntax
|
|
619
|
+
|
|
620
|
+
β **Duplicate steps** - Multiple definitions match:
|
|
621
|
+
```
|
|
622
|
+
Multiple step definitions match
|
|
623
|
+
```
|
|
624
|
+
β Remove or rename one of the duplicate step definitions
|
|
625
|
+
|
|
626
|
+
**If validation fails:**
|
|
627
|
+
1. Read the error message carefully
|
|
628
|
+
2. Fix the step definitions or scenario file **in the worktree**
|
|
629
|
+
3. Re-run the dry-run command
|
|
630
|
+
4. **Loop until validation passes** - do NOT proceed until green
|
|
631
|
+
|
|
632
|
+
**If validation succeeds:**
|
|
633
|
+
Display: "β
BDD infrastructure validated - all steps have definitions"
|
|
634
|
+
|
|
635
|
+
**Update database with scenario file path:**
|
|
636
|
+
|
|
637
|
+
```bash
|
|
638
|
+
sqlite3 .jettypod/work.db "UPDATE work_items SET scenario_file = 'features/${FEATURE_SLUG}.feature' WHERE id = ${FEATURE_ID}"
|
|
639
|
+
```
|
|
640
|
+
|
|
641
|
+
**Proceed to Step 10.**
|
|
642
|
+
|
|
643
|
+
### Step 10: Propose Speed Mode Chores
|
|
644
|
+
|
|
645
|
+
**CRITICAL:** After BDD files are written and validated, analyze the codebase and propose technical implementation chores. **DO NOT CREATE CHORES YET** - the feature must transition to implementation mode first (Step 11).
|
|
506
646
|
|
|
507
647
|
**Your analysis should consider:**
|
|
508
648
|
- The BDD scenarios (integration + all success paths)
|
|
509
|
-
- The Integration Contract from Step
|
|
649
|
+
- The Integration Contract from Step 6
|
|
510
650
|
- Existing codebase structure and patterns
|
|
511
651
|
- Epic's architectural decisions (if any)
|
|
512
652
|
- Tech stack and framework conventions
|
|
@@ -516,7 +656,7 @@ Scenario: Prevent unauthorized access
|
|
|
516
656
|
**REQUIRED: At least one chore MUST be an Integration Chore** that:
|
|
517
657
|
- Wires the feature into the existing app
|
|
518
658
|
- Makes the Integration Scenario pass
|
|
519
|
-
- Modifies the caller code identified in Step
|
|
659
|
+
- Modifies the caller code identified in Step 6
|
|
520
660
|
|
|
521
661
|
**Say to the user:**
|
|
522
662
|
|
|
@@ -530,7 +670,7 @@ Based on the scenario and my understanding of the codebase, here are the chores
|
|
|
530
670
|
**Chore 1: [Integration chore - wire feature into app]** β‘ INTEGRATION
|
|
531
671
|
- Why: Makes the feature reachable from [entry point]
|
|
532
672
|
- Integration Contract:
|
|
533
|
-
β’ Entry point: [from Step
|
|
673
|
+
β’ Entry point: [from Step 6]
|
|
534
674
|
β’ Caller code to modify: [specific file/function]
|
|
535
675
|
- Scenario steps addressed:
|
|
536
676
|
β’ [Integration scenario Given/When/Then steps]
|
|
@@ -560,17 +700,17 @@ Sound good? Any adjustments?
|
|
|
560
700
|
|
|
561
701
|
**WAIT for user response.**
|
|
562
702
|
|
|
563
|
-
- If user confirms β Proceed to Step
|
|
703
|
+
- If user confirms β Proceed to Step 11
|
|
564
704
|
- If user requests changes β Revise chore proposals, then WAIT again
|
|
565
705
|
- If user adds/removes chores β Update your list accordingly
|
|
566
706
|
|
|
567
|
-
### Step
|
|
707
|
+
### Step 11: Rationale, Create Chores, and Transition
|
|
568
708
|
|
|
569
|
-
Complete the discovery phase by transitioning the feature from discovery to implementation.
|
|
709
|
+
Complete the discovery phase by recording the decision, creating chores, and transitioning the feature from discovery to implementation.
|
|
570
710
|
|
|
571
|
-
**CRITICAL: You must EXECUTE
|
|
711
|
+
**CRITICAL: You must EXECUTE commands using the Bash tool. Do NOT just display them as text.**
|
|
572
712
|
|
|
573
|
-
####
|
|
713
|
+
#### Sub-step A: Confirm Rationale
|
|
574
714
|
|
|
575
715
|
Display to user:
|
|
576
716
|
|
|
@@ -585,11 +725,11 @@ Does this rationale capture why you chose this approach? (You can edit it if nee
|
|
|
585
725
|
|
|
586
726
|
**WAIT for user to confirm or provide edited rationale.**
|
|
587
727
|
|
|
588
|
-
####
|
|
728
|
+
#### Sub-step B: Create the Chores
|
|
589
729
|
|
|
590
730
|
**CRITICAL: Create chores BEFORE running `work implement`.** The system validates that chores exist before allowing the transition.
|
|
591
731
|
|
|
592
|
-
For each chore that the user confirmed in Step
|
|
732
|
+
For each chore that the user confirmed in Step 10, use the Bash tool to create it:
|
|
593
733
|
|
|
594
734
|
```bash
|
|
595
735
|
jettypod work create chore "[Chore title]" "[Chore description]" --parent=${FEATURE_ID}
|
|
@@ -600,24 +740,24 @@ Replace `${FEATURE_ID}` with actual ID. Example:
|
|
|
600
740
|
jettypod work create chore "Set up auth routes" "Create login/logout endpoints..." --parent=42
|
|
601
741
|
```
|
|
602
742
|
|
|
603
|
-
**CRITICAL: Copy the EXACT proposal from Step
|
|
743
|
+
**CRITICAL: Copy the EXACT proposal from Step 10 into each chore description.** Do not paraphrase or summarize - the implementation guidance must be preserved verbatim:
|
|
604
744
|
|
|
605
745
|
```
|
|
606
|
-
[Technical description from Step
|
|
746
|
+
[Technical description from Step 10]
|
|
607
747
|
|
|
608
748
|
Scenario steps addressed:
|
|
609
|
-
β’ [EXACT steps from Step
|
|
749
|
+
β’ [EXACT steps from Step 10]
|
|
610
750
|
|
|
611
751
|
Implementation guidance:
|
|
612
|
-
β’ Files to create/modify: [EXACT paths from Step
|
|
613
|
-
β’ Patterns to follow: [EXACT references from Step
|
|
614
|
-
β’ Key functions/components needed: [EXACT list from Step
|
|
752
|
+
β’ Files to create/modify: [EXACT paths from Step 10]
|
|
753
|
+
β’ Patterns to follow: [EXACT references from Step 10]
|
|
754
|
+
β’ Key functions/components needed: [EXACT list from Step 10]
|
|
615
755
|
|
|
616
756
|
Verification:
|
|
617
|
-
β’ [EXACT step definitions from Step
|
|
757
|
+
β’ [EXACT step definitions from Step 10]
|
|
618
758
|
```
|
|
619
759
|
|
|
620
|
-
####
|
|
760
|
+
#### Sub-step C: Execute Transition
|
|
621
761
|
|
|
622
762
|
**After ALL chores are created, use Bash tool to EXECUTE the work implement command:**
|
|
623
763
|
|
|
@@ -636,8 +776,8 @@ jettypod work implement 42 --winner="Simple inline form" --rationale="Fastest UX
|
|
|
636
776
|
|
|
637
777
|
**If the command fails**, check the error message:
|
|
638
778
|
- "Feature not found" β Verify the feature ID
|
|
639
|
-
- "No chores exist" β You skipped
|
|
640
|
-
- "Already in implementation" β Feature was already transitioned, proceed to Step
|
|
779
|
+
- "No chores exist" β You skipped Sub-step B - go back and create chores first
|
|
780
|
+
- "Already in implementation" β Feature was already transitioned, proceed to Step 12
|
|
641
781
|
|
|
642
782
|
After successful transition, display:
|
|
643
783
|
|
|
@@ -645,134 +785,20 @@ After successful transition, display:
|
|
|
645
785
|
β
Feature transitioned to implementation phase
|
|
646
786
|
β
Created X chores for speed mode
|
|
647
787
|
|
|
648
|
-
Now I'll
|
|
788
|
+
Now I'll merge the BDD tests to main...
|
|
649
789
|
```
|
|
650
790
|
|
|
651
791
|
**π WORKFLOW CHECKPOINT: Implementation transition complete**
|
|
652
792
|
|
|
653
793
|
```bash
|
|
654
|
-
jettypod workflow checkpoint <feature-id> --step=
|
|
655
|
-
```
|
|
656
|
-
|
|
657
|
-
**Proceed to Step 8D.**
|
|
658
|
-
|
|
659
|
-
#### Step 8D: Write Tests in Isolated Worktree
|
|
660
|
-
|
|
661
|
-
**CRITICAL:** Tests are written in an isolated worktree, not directly on main. This ensures agent failures don't leave uncommitted garbage on main.
|
|
662
|
-
|
|
663
|
-
**π« FORBIDDEN: Manual Git Worktree Commands**
|
|
664
|
-
```
|
|
665
|
-
β git worktree add ...
|
|
666
|
-
β git checkout -b tests/...
|
|
667
|
-
β git branch tests/...
|
|
668
|
-
```
|
|
669
|
-
**ALWAYS use jettypod commands** - they handle branch naming, path conventions, database tracking, and cleanup. Manual git commands will create orphaned worktrees that break the merge workflow.
|
|
670
|
-
|
|
671
|
-
**Sub-step 1: Create test worktree**
|
|
672
|
-
|
|
673
|
-
```bash
|
|
674
|
-
jettypod work tests start ${FEATURE_ID}
|
|
675
|
-
```
|
|
676
|
-
|
|
677
|
-
This creates:
|
|
678
|
-
- Worktree at `.jettypod-work/tests-<id>-<slug>/`
|
|
679
|
-
- Branch `tests/feature-<id>-<slug>`
|
|
680
|
-
|
|
681
|
-
**Capture the worktree path from output** - you'll need it for file operations.
|
|
682
|
-
|
|
683
|
-
Example output:
|
|
684
|
-
```
|
|
685
|
-
β
Created test worktree: /path/to/.jettypod-work/tests-42-email-login
|
|
686
|
-
Branch: tests/feature-42-email-login
|
|
687
|
-
|
|
688
|
-
Write your BDD files to:
|
|
689
|
-
<worktree>/features/email-login.feature
|
|
690
|
-
<worktree>/features/step_definitions/email-login.steps.js
|
|
691
|
-
|
|
692
|
-
When done, merge then cleanup:
|
|
693
|
-
jettypod work tests merge 42
|
|
694
|
-
cd /path/to/main/repo
|
|
695
|
-
jettypod work cleanup 42
|
|
696
|
-
```
|
|
697
|
-
|
|
698
|
-
**π STOP AND CHECK:** Verify worktree was created successfully. If you see an error, investigate before continuing.
|
|
699
|
-
|
|
700
|
-
**Sub-step 2: Write BDD files in the worktree**
|
|
701
|
-
|
|
702
|
-
Using the scenarios you confirmed in Step 6B, write the files using **absolute paths to the worktree**:
|
|
703
|
-
|
|
704
|
-
**A. Write scenario file** using Write tool:
|
|
705
|
-
```
|
|
706
|
-
<worktree_path>/features/${FEATURE_SLUG}.feature
|
|
707
|
-
```
|
|
708
|
-
|
|
709
|
-
**B. Write step definitions file** using Write tool:
|
|
710
|
-
```
|
|
711
|
-
<worktree_path>/features/step_definitions/${FEATURE_SLUG}.steps.js
|
|
712
|
-
```
|
|
713
|
-
|
|
714
|
-
**Step definition requirements:**
|
|
715
|
-
1. Implement all Given/When/Then steps from the scenarios
|
|
716
|
-
2. Follow existing patterns - check other `.steps.js` files for conventions
|
|
717
|
-
3. Include test environment setup/cleanup
|
|
718
|
-
4. All Given steps (setup state)
|
|
719
|
-
5. All When steps (execute actions)
|
|
720
|
-
6. All Then steps (verify outcomes)
|
|
721
|
-
|
|
722
|
-
**Sub-step 3: Validate BDD infrastructure**
|
|
723
|
-
|
|
724
|
-
Run cucumber dry-run **from within the worktree**:
|
|
725
|
-
|
|
726
|
-
```bash
|
|
727
|
-
cd <worktree_path> && npx cucumber-js --dry-run features/${FEATURE_SLUG}.feature
|
|
794
|
+
jettypod workflow checkpoint <feature-id> --step=11
|
|
728
795
|
```
|
|
729
796
|
|
|
730
|
-
**
|
|
731
|
-
|
|
732
|
-
β
**Success** - No errors, all steps have definitions:
|
|
733
|
-
```
|
|
734
|
-
0 scenarios
|
|
735
|
-
0 steps
|
|
736
|
-
```
|
|
737
|
-
(Dry-run doesn't execute, so 0 is correct)
|
|
797
|
+
**Proceed to Step 12.**
|
|
738
798
|
|
|
739
|
-
|
|
740
|
-
```
|
|
741
|
-
Undefined. Implement with the following snippet:
|
|
742
|
-
Given('I am on the login page', function () {
|
|
743
|
-
...
|
|
744
|
-
});
|
|
745
|
-
```
|
|
746
|
-
β Add the missing step definition to your `.steps.js` file
|
|
747
|
-
|
|
748
|
-
β **Syntax error** - Invalid Gherkin:
|
|
749
|
-
```
|
|
750
|
-
Parse error in features/foo.feature
|
|
751
|
-
```
|
|
752
|
-
β Fix the feature file syntax
|
|
753
|
-
|
|
754
|
-
β **Duplicate steps** - Multiple definitions match:
|
|
755
|
-
```
|
|
756
|
-
Multiple step definitions match
|
|
757
|
-
```
|
|
758
|
-
β Remove or rename one of the duplicate step definitions
|
|
759
|
-
|
|
760
|
-
**If validation fails:**
|
|
761
|
-
1. Read the error message carefully
|
|
762
|
-
2. Fix the step definitions or scenario file **in the worktree**
|
|
763
|
-
3. Re-run the dry-run command
|
|
764
|
-
4. **Loop until validation passes** - do NOT proceed until green
|
|
765
|
-
|
|
766
|
-
**If validation succeeds:**
|
|
767
|
-
Display: "β
BDD infrastructure validated - all steps have definitions"
|
|
768
|
-
|
|
769
|
-
**Sub-step 4: Update database with scenario file path**
|
|
770
|
-
|
|
771
|
-
```bash
|
|
772
|
-
sqlite3 .jettypod/work.db "UPDATE work_items SET scenario_file = 'features/${FEATURE_SLUG}.feature' WHERE id = ${FEATURE_ID}"
|
|
773
|
-
```
|
|
799
|
+
### Step 12: Merge Tests to Main
|
|
774
800
|
|
|
775
|
-
|
|
801
|
+
The BDD files were written in Step 9. Now merge them to main.
|
|
776
802
|
|
|
777
803
|
**Merge and cleanup (3 steps):**
|
|
778
804
|
|
|
@@ -799,7 +825,7 @@ This will:
|
|
|
799
825
|
- Mark worktree as merged (cleanup is separate)
|
|
800
826
|
|
|
801
827
|
**π STOP AND CHECK:** Verify merge succeeded:
|
|
802
|
-
- β
"Tests merged to main" β Proceed to Step
|
|
828
|
+
- β
"Tests merged to main" β Proceed to Step 13
|
|
803
829
|
- β Error β Investigate, worktree still exists for debugging
|
|
804
830
|
|
|
805
831
|
**After successful merge, display:**
|
|
@@ -832,9 +858,9 @@ jettypod workflow complete feature-planning <feature-id>
|
|
|
832
858
|
|
|
833
859
|
This marks the `feature_planning_complete` gate as passed, enabling speed-mode to start.
|
|
834
860
|
|
|
835
|
-
**Proceed to Step
|
|
861
|
+
**Proceed to Step 13.**
|
|
836
862
|
|
|
837
|
-
|
|
863
|
+
### Step 13: Start First Chore
|
|
838
864
|
|
|
839
865
|
**Feature planning is now complete.** The feature has been transitioned to implementation phase, tests are on main, and chores are ready.
|
|
840
866
|
|
|
@@ -957,15 +983,15 @@ Before completing feature planning, ensure:
|
|
|
957
983
|
- [ ] Exactly 3 approaches suggested
|
|
958
984
|
- [ ] Winner chosen (with prototypes or without)
|
|
959
985
|
- [ ] **Integration Contract defined** (entry point, caller code, integration scenario)
|
|
986
|
+
- [ ] **Test worktree created** with `work tests start` (Step 7)
|
|
960
987
|
- [ ] **Integration Scenario is FIRST scenario** in proposed scenarios
|
|
961
|
-
- [ ] BDD scenarios **proposed and confirmed** by user (Step
|
|
988
|
+
- [ ] BDD scenarios **proposed and confirmed** by user (Step 8)
|
|
989
|
+
- [ ] **BDD files written** in worktree using `WORKTREE_PATH` (Step 9)
|
|
990
|
+
- [ ] **BDD infrastructure validated** with dry-run (Step 9)
|
|
962
991
|
- [ ] **At least one Integration Chore proposed** (wires feature into app)
|
|
963
|
-
- [ ] Speed mode chores proposed and confirmed (Step
|
|
964
|
-
- [ ] Chores created in database (Step
|
|
965
|
-
- [ ] Feature transitioned to implementation with `work implement` (Step
|
|
966
|
-
- [ ] **
|
|
967
|
-
- [ ]
|
|
968
|
-
- [ ] **
|
|
969
|
-
- [ ] **Tests merged to main** with `work tests merge` β `cd` β `work cleanup` (Step 8D)
|
|
970
|
-
- [ ] First chore started with `work start [chore-id]` (Step 8E)
|
|
971
|
-
- [ ] **Speed-mode skill invoked using Skill tool** (Step 8E)
|
|
992
|
+
- [ ] Speed mode chores proposed and confirmed (Step 10)
|
|
993
|
+
- [ ] Chores created in database (Step 11)
|
|
994
|
+
- [ ] Feature transitioned to implementation with `work implement` (Step 11)
|
|
995
|
+
- [ ] **Tests merged to main** with `work tests merge` β `cd` β `work cleanup` (Step 12)
|
|
996
|
+
- [ ] First chore started with `work start [chore-id]` (Step 13)
|
|
997
|
+
- [ ] **Speed-mode skill invoked using Skill tool** (Step 13)
|
|
@@ -30,12 +30,72 @@ When this skill is activated, you are helping implement a production mode chore
|
|
|
30
30
|
|
|
31
31
|
---
|
|
32
32
|
|
|
33
|
+
## π PRE-FLIGHT VALIDATION (REQUIRED)
|
|
34
|
+
|
|
35
|
+
**Before proceeding with ANY implementation, you MUST validate the worktree exists.**
|
|
36
|
+
|
|
37
|
+
Run this query FIRST:
|
|
38
|
+
|
|
39
|
+
```bash
|
|
40
|
+
sqlite3 .jettypod/work.db "SELECT wi.id, wi.title, wi.status, wt.worktree_path, wt.branch_name FROM work_items wi LEFT JOIN worktrees wt ON wi.id = wt.work_item_id WHERE wi.status = 'in_progress' AND wi.type = 'chore'"
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
**Check the result:**
|
|
44
|
+
|
|
45
|
+
| worktree_path | What it means | Action |
|
|
46
|
+
|---------------|---------------|--------|
|
|
47
|
+
| **Has a path** (e.g., `/path/to/.jettypod-work/...`) | β
Worktree exists, ready to proceed | Continue to Step 0 |
|
|
48
|
+
| **NULL or empty** | β `work start` was not called | **STOP - run `jettypod work start [chore-id]` first** |
|
|
49
|
+
| **No rows returned** | β No chore is in progress | **STOP - verify the chore exists and run `work start`** |
|
|
50
|
+
|
|
51
|
+
**π STOP GATE:** If `worktree_path` is NULL or no rows returned, you MUST run `jettypod work start [chore-id]` before continuing. DO NOT proceed without a valid worktree.
|
|
52
|
+
|
|
53
|
+
**π« FORBIDDEN: Manual Git Worktree Commands**
|
|
54
|
+
```
|
|
55
|
+
β git worktree add ...
|
|
56
|
+
β git checkout -b feature/...
|
|
57
|
+
β git branch feature/...
|
|
58
|
+
```
|
|
59
|
+
**ALWAYS use `jettypod work start`** - it handles branch naming, path conventions, database tracking, and cleanup. Manual git commands will create orphaned worktrees that break the merge workflow.
|
|
60
|
+
|
|
61
|
+
---
|
|
62
|
+
|
|
63
|
+
## π WORKTREE PATH LOCK
|
|
64
|
+
|
|
65
|
+
**After pre-flight validation passes, capture and lock the worktree path:**
|
|
66
|
+
|
|
67
|
+
From the pre-flight query output, extract and store:
|
|
68
|
+
- `WORKTREE_PATH` - the absolute path to the worktree
|
|
69
|
+
|
|
70
|
+
**Display:**
|
|
71
|
+
|
|
72
|
+
```
|
|
73
|
+
π WORKTREE LOCK ACTIVE
|
|
74
|
+
Path: ${WORKTREE_PATH}
|
|
75
|
+
|
|
76
|
+
All file writes will use this path.
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
**From this point forward, ALL file operations MUST use paths starting with `${WORKTREE_PATH}/`**
|
|
80
|
+
|
|
81
|
+
This lock prevents accidental writes to the main repository.
|
|
82
|
+
|
|
83
|
+
---
|
|
84
|
+
|
|
33
85
|
## Implementation Steps
|
|
34
86
|
|
|
35
87
|
### Step 0: Detect Production Context (CRITICAL FIRST STEP)
|
|
36
88
|
|
|
37
89
|
**MUST RUN FIRST:** Detect which scenario applies to this feature.
|
|
38
90
|
|
|
91
|
+
**π« FORBIDDEN: Writing Files at This Step**
|
|
92
|
+
```
|
|
93
|
+
β Write tool to any path
|
|
94
|
+
β Edit tool to any path
|
|
95
|
+
β Any file creation or modification
|
|
96
|
+
```
|
|
97
|
+
**This is a DETECTION step.** File writes happen in Step 3.
|
|
98
|
+
|
|
39
99
|
**To detect context, check these conditions:**
|
|
40
100
|
|
|
41
101
|
```bash
|
|
@@ -89,6 +149,14 @@ This validates that `stable_mode_complete` gate is passed and creates an executi
|
|
|
89
149
|
|
|
90
150
|
**For all scenarios:** Read production standards file.
|
|
91
151
|
|
|
152
|
+
**π« FORBIDDEN: Writing Files at This Step**
|
|
153
|
+
```
|
|
154
|
+
β Write tool to any path
|
|
155
|
+
β Edit tool to any path
|
|
156
|
+
β Any file creation or modification
|
|
157
|
+
```
|
|
158
|
+
**This is a READ step.** File writes happen in Step 3.
|
|
159
|
+
|
|
92
160
|
```bash
|
|
93
161
|
# Check if production standards file exists
|
|
94
162
|
ls .jettypod/production-standards.json
|
|
@@ -111,6 +179,14 @@ jettypod workflow checkpoint <feature-id> --step=1
|
|
|
111
179
|
|
|
112
180
|
**For Scenario A only:** Quick validation of existing scenarios.
|
|
113
181
|
|
|
182
|
+
**π« FORBIDDEN: Writing Files at This Step**
|
|
183
|
+
```
|
|
184
|
+
β Write tool to any path
|
|
185
|
+
β Edit tool to any path
|
|
186
|
+
β Any file creation or modification
|
|
187
|
+
```
|
|
188
|
+
**This is a VALIDATION step.** File writes happen in Step 3.
|
|
189
|
+
|
|
114
190
|
```javascript
|
|
115
191
|
const { validateScenarios } = require('../../lib/production-scenario-validator');
|
|
116
192
|
const { getDb } = require('../../lib/database');
|
|
@@ -168,6 +244,14 @@ try {
|
|
|
168
244
|
|
|
169
245
|
**For Scenario B only:** Re-validate with current standards.
|
|
170
246
|
|
|
247
|
+
**π« FORBIDDEN: Writing Files at This Step**
|
|
248
|
+
```
|
|
249
|
+
β Write tool to any path
|
|
250
|
+
β Edit tool to any path
|
|
251
|
+
β Any file creation or modification
|
|
252
|
+
```
|
|
253
|
+
**This is a VALIDATION step.** File writes happen in Step 3.
|
|
254
|
+
|
|
171
255
|
```javascript
|
|
172
256
|
const { validateScenarios } = require('../../lib/production-scenario-validator');
|
|
173
257
|
const config = require('../../lib/config');
|
|
@@ -223,6 +307,14 @@ try {
|
|
|
223
307
|
|
|
224
308
|
**For Scenario C only:** Generate production scenarios from standards.
|
|
225
309
|
|
|
310
|
+
**π« FORBIDDEN: Writing Files at This Step**
|
|
311
|
+
```
|
|
312
|
+
β Write tool to any path
|
|
313
|
+
β Edit tool to any path
|
|
314
|
+
β Any file creation or modification
|
|
315
|
+
```
|
|
316
|
+
**This is a GENERATION step (via jettypod commands, not direct file writes).** File writes happen in Step 3.
|
|
317
|
+
|
|
226
318
|
```bash
|
|
227
319
|
# Get feature details
|
|
228
320
|
sqlite3 .jettypod/work.db "SELECT id, title, scenario_file FROM work_items WHERE id = <feature-id>"
|
|
@@ -247,6 +339,10 @@ jettypod workflow checkpoint <feature-id> --step=2
|
|
|
247
339
|
|
|
248
340
|
### Step 3: Implement Production Chore
|
|
249
341
|
|
|
342
|
+
**π WORKTREE PATH REQUIRED:** All file writes MUST use the `WORKTREE_PATH` captured after pre-flight validation.
|
|
343
|
+
|
|
344
|
+
**β
NOW you may write files** - worktree is locked, context is detected.
|
|
345
|
+
|
|
250
346
|
**For all scenarios:** Implement the current production chore with test-driven iteration.
|
|
251
347
|
|
|
252
348
|
**Get current work and identify target scenario:**
|
|
@@ -102,6 +102,28 @@ sqlite3 .jettypod/work.db "SELECT wi.id, wi.title, wi.status, wt.worktree_path,
|
|
|
102
102
|
|
|
103
103
|
---
|
|
104
104
|
|
|
105
|
+
## π WORKTREE PATH LOCK
|
|
106
|
+
|
|
107
|
+
**After pre-flight validation passes, capture and lock the worktree path:**
|
|
108
|
+
|
|
109
|
+
From the pre-flight query output, extract and store:
|
|
110
|
+
- `WORKTREE_PATH` - the absolute path to the worktree (e.g., `/path/to/.jettypod-work/4-add-nav-link`)
|
|
111
|
+
|
|
112
|
+
**Display:**
|
|
113
|
+
```
|
|
114
|
+
π WORKTREE LOCK ACTIVE
|
|
115
|
+
Path: ${WORKTREE_PATH}
|
|
116
|
+
|
|
117
|
+
All file writes will use this path.
|
|
118
|
+
```
|
|
119
|
+
|
|
120
|
+
**From this point forward, ALL file operations MUST use paths starting with:**
|
|
121
|
+
```
|
|
122
|
+
${WORKTREE_PATH}/
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
---
|
|
126
|
+
|
|
105
127
|
### Overview
|
|
106
128
|
|
|
107
129
|
**Speed Mode Goal:** Make it work - implement ALL functionality (integration + required + optional features) to make success scenarios pass, assuming everything works correctly.
|
|
@@ -269,6 +291,14 @@ Analyzing BDD scenarios to determine implementation approach...
|
|
|
269
291
|
|
|
270
292
|
### Step 1: Check for Breadcrumbs and Analyze Scenario
|
|
271
293
|
|
|
294
|
+
**π« FORBIDDEN: Writing Files at This Step**
|
|
295
|
+
```
|
|
296
|
+
β Write tool to any path
|
|
297
|
+
β Edit tool to any path
|
|
298
|
+
β Any file creation or modification
|
|
299
|
+
```
|
|
300
|
+
**This is an ANALYSIS step.** File writes happen in Step 5.
|
|
301
|
+
|
|
272
302
|
**CRITICAL:** Claude Code executes this autonomously - no user permission needed.
|
|
273
303
|
|
|
274
304
|
**Your task:**
|
|
@@ -340,6 +370,14 @@ Now analyzing codebase to propose implementation...
|
|
|
340
370
|
|
|
341
371
|
### Step 2: Autonomous Codebase Analysis
|
|
342
372
|
|
|
373
|
+
**π« FORBIDDEN: Writing Files at This Step**
|
|
374
|
+
```
|
|
375
|
+
β Write tool to any path
|
|
376
|
+
β Edit tool to any path
|
|
377
|
+
β Any file creation or modification
|
|
378
|
+
```
|
|
379
|
+
**This is an ANALYSIS step.** File writes happen in Step 5.
|
|
380
|
+
|
|
343
381
|
**CRITICAL:** Claude Code executes this autonomously - no user permission needed.
|
|
344
382
|
|
|
345
383
|
**Your task:**
|
|
@@ -416,6 +454,14 @@ jettypod workflow checkpoint <feature-id> --step=2
|
|
|
416
454
|
|
|
417
455
|
### Step 3: Decide if Confirmation Needed
|
|
418
456
|
|
|
457
|
+
**π« FORBIDDEN: Writing Files at This Step**
|
|
458
|
+
```
|
|
459
|
+
β Write tool to any path
|
|
460
|
+
β Edit tool to any path
|
|
461
|
+
β Any file creation or modification
|
|
462
|
+
```
|
|
463
|
+
**This is a DECISION step.** File writes happen in Step 5.
|
|
464
|
+
|
|
419
465
|
**Evaluate if you need user confirmation before implementing:**
|
|
420
466
|
|
|
421
467
|
**Skip confirmation (proceed directly to Step 4) if:**
|
|
@@ -432,6 +478,14 @@ jettypod workflow checkpoint <feature-id> --step=2
|
|
|
432
478
|
|
|
433
479
|
### Step 3A: Propose Implementation Approach (Conditional)
|
|
434
480
|
|
|
481
|
+
**π« FORBIDDEN: Writing Files at This Step**
|
|
482
|
+
```
|
|
483
|
+
β Write tool to any path
|
|
484
|
+
β Edit tool to any path
|
|
485
|
+
β Any file creation or modification
|
|
486
|
+
```
|
|
487
|
+
**This is a PROPOSAL step.** File writes happen in Step 5.
|
|
488
|
+
|
|
435
489
|
**β‘ ASYNC BOUNDARY - Only execute this if confirmation needed**
|
|
436
490
|
|
|
437
491
|
**Present your analysis and proposal to the user:**
|
|
@@ -514,6 +568,10 @@ jettypod workflow checkpoint <feature-id> --step=4
|
|
|
514
568
|
|
|
515
569
|
### Step 5: REDβGREENβREFACTOR Loop
|
|
516
570
|
|
|
571
|
+
**π WORKTREE PATH REQUIRED:** All file writes MUST use the `WORKTREE_PATH` captured after pre-flight validation.
|
|
572
|
+
|
|
573
|
+
**β
NOW you may write files** - worktree is locked, approach is confirmed.
|
|
574
|
+
|
|
517
575
|
**Execute autonomously** - iterate until tests pass (max 10 iterations).
|
|
518
576
|
|
|
519
577
|
**Each iteration (True TDD):**
|
|
@@ -109,6 +109,28 @@ sqlite3 .jettypod/work.db "SELECT wi.id, wi.title, wi.status, wt.worktree_path,
|
|
|
109
109
|
|
|
110
110
|
---
|
|
111
111
|
|
|
112
|
+
## π WORKTREE PATH LOCK
|
|
113
|
+
|
|
114
|
+
**After pre-flight validation passes, capture and lock the worktree path:**
|
|
115
|
+
|
|
116
|
+
From the pre-flight query output, extract and store:
|
|
117
|
+
- `WORKTREE_PATH` - the absolute path to the worktree
|
|
118
|
+
|
|
119
|
+
**Display:**
|
|
120
|
+
|
|
121
|
+
```
|
|
122
|
+
π WORKTREE LOCK ACTIVE
|
|
123
|
+
Path: ${WORKTREE_PATH}
|
|
124
|
+
|
|
125
|
+
All file writes will use this path.
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
**From this point forward, ALL file operations MUST use paths starting with `${WORKTREE_PATH}/`**
|
|
129
|
+
|
|
130
|
+
This lock prevents accidental writes to the main repository.
|
|
131
|
+
|
|
132
|
+
---
|
|
133
|
+
|
|
112
134
|
### Overview
|
|
113
135
|
|
|
114
136
|
**Stable Mode Goal:** Transform speed mode's "make it work" implementation into robust, reliable code with comprehensive error handling and validation.
|
|
@@ -271,6 +293,14 @@ Analyzing stable mode BDD scenarios to determine what error handling and validat
|
|
|
271
293
|
|
|
272
294
|
**CRITICAL:** Claude Code executes this autonomously - no user permission needed.
|
|
273
295
|
|
|
296
|
+
**π« FORBIDDEN: Writing Files at This Step**
|
|
297
|
+
```
|
|
298
|
+
β Write tool to any path
|
|
299
|
+
β Edit tool to any path
|
|
300
|
+
β Any file creation or modification
|
|
301
|
+
```
|
|
302
|
+
**This is an ANALYSIS step.** File writes happen in Step 5.
|
|
303
|
+
|
|
274
304
|
**Your task:**
|
|
275
305
|
1. Get current work item and parent feature's scenario file
|
|
276
306
|
2. Read the full scenario file (should have success scenarios + stable mode error/edge case scenarios)
|
|
@@ -328,6 +358,14 @@ Now reviewing speed mode implementation...
|
|
|
328
358
|
|
|
329
359
|
**CRITICAL:** Claude Code executes this autonomously - no user permission needed.
|
|
330
360
|
|
|
361
|
+
**π« FORBIDDEN: Writing Files at This Step**
|
|
362
|
+
```
|
|
363
|
+
β Write tool to any path
|
|
364
|
+
β Edit tool to any path
|
|
365
|
+
β Any file creation or modification
|
|
366
|
+
```
|
|
367
|
+
**This is an ANALYSIS step.** File writes happen in Step 5.
|
|
368
|
+
|
|
331
369
|
**Your task:**
|
|
332
370
|
1. Find files created/modified in speed mode
|
|
333
371
|
2. Read the existing implementation
|
|
@@ -380,6 +418,14 @@ jettypod workflow checkpoint <feature-id> --step=2
|
|
|
380
418
|
|
|
381
419
|
### Step 3: Decide if Confirmation Needed
|
|
382
420
|
|
|
421
|
+
**π« FORBIDDEN: Writing Files at This Step**
|
|
422
|
+
```
|
|
423
|
+
β Write tool to any path
|
|
424
|
+
β Edit tool to any path
|
|
425
|
+
β Any file creation or modification
|
|
426
|
+
```
|
|
427
|
+
**This is a DECISION step.** File writes happen in Step 5.
|
|
428
|
+
|
|
383
429
|
**Evaluate if you need user confirmation before implementing:**
|
|
384
430
|
|
|
385
431
|
**Skip confirmation (proceed directly to Step 4) if:**
|
|
@@ -398,6 +444,14 @@ jettypod workflow checkpoint <feature-id> --step=2
|
|
|
398
444
|
|
|
399
445
|
**β‘ ASYNC BOUNDARY - Only execute this if confirmation needed**
|
|
400
446
|
|
|
447
|
+
**π« FORBIDDEN: Writing Files at This Step**
|
|
448
|
+
```
|
|
449
|
+
β Write tool to any path
|
|
450
|
+
β Edit tool to any path
|
|
451
|
+
β Any file creation or modification
|
|
452
|
+
```
|
|
453
|
+
**This is a PROPOSAL step.** File writes happen in Step 5.
|
|
454
|
+
|
|
401
455
|
**Present your analysis and proposal to the user:**
|
|
402
456
|
|
|
403
457
|
```
|
|
@@ -496,6 +550,10 @@ jettypod workflow checkpoint <feature-id> --step=4
|
|
|
496
550
|
|
|
497
551
|
### Step 5: REDβGREENβREFACTOR Loop
|
|
498
552
|
|
|
553
|
+
**π WORKTREE PATH REQUIRED:** All file writes MUST use the `WORKTREE_PATH` captured after pre-flight validation.
|
|
554
|
+
|
|
555
|
+
**β
NOW you may write files** - worktree is locked, approach is confirmed.
|
|
556
|
+
|
|
499
557
|
**Execute autonomously** - iterate until tests pass (max 10 iterations).
|
|
500
558
|
|
|
501
559
|
**Each iteration (True TDD):**
|