@sienklogic/plan-build-run 2.10.0 → 2.11.0
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/CHANGELOG.md +37 -0
- package/package.json +1 -1
- package/plugins/copilot-pbr/agents/codebase-mapper.agent.md +42 -0
- package/plugins/copilot-pbr/agents/debugger.agent.md +4 -1
- package/plugins/copilot-pbr/agents/executor.agent.md +31 -1
- package/plugins/copilot-pbr/agents/integration-checker.agent.md +33 -2
- package/plugins/copilot-pbr/agents/planner.agent.md +58 -1
- package/plugins/copilot-pbr/agents/researcher.agent.md +23 -0
- package/plugins/copilot-pbr/agents/synthesizer.agent.md +24 -0
- package/plugins/copilot-pbr/agents/verifier.agent.md +35 -1
- package/plugins/copilot-pbr/plugin.json +1 -1
- package/plugins/copilot-pbr/references/agent-contracts.md +297 -0
- package/plugins/copilot-pbr/references/ui-formatting.md +38 -56
- package/plugins/copilot-pbr/skills/begin/SKILL.md +30 -7
- package/plugins/copilot-pbr/skills/build/SKILL.md +28 -31
- package/plugins/copilot-pbr/skills/config/SKILL.md +9 -12
- package/plugins/copilot-pbr/skills/continue/SKILL.md +6 -6
- package/plugins/copilot-pbr/skills/dashboard/SKILL.md +3 -3
- package/plugins/copilot-pbr/skills/debug/SKILL.md +23 -26
- package/plugins/copilot-pbr/skills/discuss/SKILL.md +20 -10
- package/plugins/copilot-pbr/skills/do/SKILL.md +3 -3
- package/plugins/copilot-pbr/skills/explore/SKILL.md +11 -14
- package/plugins/copilot-pbr/skills/health/SKILL.md +75 -19
- package/plugins/copilot-pbr/skills/help/SKILL.md +6 -6
- package/plugins/copilot-pbr/skills/import/SKILL.md +22 -18
- package/plugins/copilot-pbr/skills/milestone/SKILL.md +90 -48
- package/plugins/copilot-pbr/skills/note/SKILL.md +3 -3
- package/plugins/copilot-pbr/skills/pause/SKILL.md +11 -10
- package/plugins/copilot-pbr/skills/plan/SKILL.md +22 -9
- package/plugins/copilot-pbr/skills/plan/templates/planner-prompt.md.tmpl +1 -1
- package/plugins/copilot-pbr/skills/quick/SKILL.md +9 -12
- package/plugins/copilot-pbr/skills/resume/SKILL.md +9 -9
- package/plugins/copilot-pbr/skills/review/SKILL.md +17 -12
- package/plugins/copilot-pbr/skills/scan/SKILL.md +9 -11
- package/plugins/copilot-pbr/skills/setup/SKILL.md +31 -8
- package/plugins/copilot-pbr/skills/shared/error-reporting.md +2 -1
- package/plugins/copilot-pbr/skills/shared/progress-display.md +0 -1
- package/plugins/copilot-pbr/skills/shared/universal-anti-patterns.md +10 -6
- package/plugins/copilot-pbr/skills/status/SKILL.md +3 -3
- package/plugins/copilot-pbr/skills/statusline/SKILL.md +12 -8
- package/plugins/copilot-pbr/skills/todo/SKILL.md +51 -28
- package/plugins/cursor-pbr/.cursor-plugin/plugin.json +1 -1
- package/plugins/cursor-pbr/agents/codebase-mapper.md +42 -0
- package/plugins/cursor-pbr/agents/debugger.md +4 -1
- package/plugins/cursor-pbr/agents/executor.md +31 -1
- package/plugins/cursor-pbr/agents/integration-checker.md +33 -2
- package/plugins/cursor-pbr/agents/planner.md +58 -1
- package/plugins/cursor-pbr/agents/researcher.md +23 -0
- package/plugins/cursor-pbr/agents/synthesizer.md +24 -0
- package/plugins/cursor-pbr/agents/verifier.md +35 -1
- package/plugins/cursor-pbr/references/agent-contracts.md +297 -0
- package/plugins/cursor-pbr/references/ui-formatting.md +38 -56
- package/plugins/cursor-pbr/skills/begin/SKILL.md +30 -7
- package/plugins/cursor-pbr/skills/build/SKILL.md +28 -31
- package/plugins/cursor-pbr/skills/config/SKILL.md +9 -10
- package/plugins/cursor-pbr/skills/continue/SKILL.md +6 -6
- package/plugins/cursor-pbr/skills/dashboard/SKILL.md +3 -3
- package/plugins/cursor-pbr/skills/debug/SKILL.md +23 -23
- package/plugins/cursor-pbr/skills/discuss/SKILL.md +20 -10
- package/plugins/cursor-pbr/skills/do/SKILL.md +3 -3
- package/plugins/cursor-pbr/skills/explore/SKILL.md +11 -12
- package/plugins/cursor-pbr/skills/health/SKILL.md +75 -19
- package/plugins/cursor-pbr/skills/help/SKILL.md +6 -6
- package/plugins/cursor-pbr/skills/import/SKILL.md +22 -16
- package/plugins/cursor-pbr/skills/milestone/SKILL.md +90 -48
- package/plugins/cursor-pbr/skills/note/SKILL.md +3 -3
- package/plugins/cursor-pbr/skills/pause/SKILL.md +11 -9
- package/plugins/cursor-pbr/skills/plan/SKILL.md +22 -9
- package/plugins/cursor-pbr/skills/plan/templates/planner-prompt.md.tmpl +1 -1
- package/plugins/cursor-pbr/skills/quick/SKILL.md +9 -12
- package/plugins/cursor-pbr/skills/resume/SKILL.md +9 -9
- package/plugins/cursor-pbr/skills/review/SKILL.md +17 -12
- package/plugins/cursor-pbr/skills/scan/SKILL.md +9 -10
- package/plugins/cursor-pbr/skills/setup/SKILL.md +31 -8
- package/plugins/cursor-pbr/skills/shared/error-reporting.md +2 -1
- package/plugins/cursor-pbr/skills/shared/progress-display.md +0 -1
- package/plugins/cursor-pbr/skills/shared/universal-anti-patterns.md +10 -6
- package/plugins/cursor-pbr/skills/status/SKILL.md +3 -3
- package/plugins/cursor-pbr/skills/statusline/SKILL.md +12 -8
- package/plugins/cursor-pbr/skills/todo/SKILL.md +51 -28
- package/plugins/pbr/.claude-plugin/plugin.json +1 -1
- package/plugins/pbr/agents/codebase-mapper.md +42 -0
- package/plugins/pbr/agents/debugger.md +4 -1
- package/plugins/pbr/agents/executor.md +31 -1
- package/plugins/pbr/agents/integration-checker.md +34 -2
- package/plugins/pbr/agents/planner.md +58 -1
- package/plugins/pbr/agents/researcher.md +23 -0
- package/plugins/pbr/agents/synthesizer.md +24 -0
- package/plugins/pbr/agents/verifier.md +36 -1
- package/plugins/pbr/references/agent-contracts.md +297 -0
- package/plugins/pbr/references/ui-formatting.md +37 -54
- package/plugins/pbr/scripts/check-skill-workflow.js +11 -0
- package/plugins/pbr/scripts/check-state-sync.js +58 -0
- package/plugins/pbr/scripts/check-subagent-output.js +43 -4
- package/plugins/pbr/scripts/validate-task.js +69 -17
- package/plugins/pbr/skills/begin/SKILL.md +36 -11
- package/plugins/pbr/skills/build/SKILL.md +37 -25
- package/plugins/pbr/skills/config/SKILL.md +12 -10
- package/plugins/pbr/skills/continue/SKILL.md +11 -9
- package/plugins/pbr/skills/dashboard/SKILL.md +3 -3
- package/plugins/pbr/skills/debug/SKILL.md +29 -23
- package/plugins/pbr/skills/discuss/SKILL.md +20 -10
- package/plugins/pbr/skills/do/SKILL.md +3 -3
- package/plugins/pbr/skills/explore/SKILL.md +14 -12
- package/plugins/pbr/skills/health/SKILL.md +76 -20
- package/plugins/pbr/skills/help/SKILL.md +8 -6
- package/plugins/pbr/skills/import/SKILL.md +25 -16
- package/plugins/pbr/skills/milestone/SKILL.md +88 -45
- package/plugins/pbr/skills/note/SKILL.md +3 -3
- package/plugins/pbr/skills/pause/SKILL.md +13 -9
- package/plugins/pbr/skills/plan/SKILL.md +28 -13
- package/plugins/pbr/skills/plan/templates/planner-prompt.md.tmpl +1 -1
- package/plugins/pbr/skills/quick/SKILL.md +12 -10
- package/plugins/pbr/skills/resume/SKILL.md +11 -9
- package/plugins/pbr/skills/review/SKILL.md +35 -24
- package/plugins/pbr/skills/scan/SKILL.md +12 -10
- package/plugins/pbr/skills/setup/SKILL.md +30 -7
- package/plugins/pbr/skills/shared/error-reporting.md +2 -0
- package/plugins/pbr/skills/shared/universal-anti-patterns.md +10 -6
- package/plugins/pbr/skills/status/SKILL.md +8 -6
- package/plugins/pbr/skills/statusline/SKILL.md +12 -8
- package/plugins/pbr/skills/todo/SKILL.md +51 -28
|
@@ -19,9 +19,9 @@ This skill **spawns a single Task(subagent_type: "pbr:executor")** for execution
|
|
|
19
19
|
**Before ANY tool calls**, display this banner:
|
|
20
20
|
|
|
21
21
|
```
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
22
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
23
|
+
║ PLAN-BUILD-RUN ► QUICK TASK ║
|
|
24
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
25
25
|
```
|
|
26
26
|
|
|
27
27
|
Then proceed to Step 1.
|
|
@@ -250,17 +250,19 @@ Display results to the user with branded output:
|
|
|
250
250
|
|
|
251
251
|
**If completed:**
|
|
252
252
|
```
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
253
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
254
|
+
║ PLAN-BUILD-RUN ► QUICK TASK COMPLETE ✓ ║
|
|
255
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
256
256
|
|
|
257
257
|
**Quick Task {NNN}:** {description}
|
|
258
258
|
Commit: {hash} — {commit message}
|
|
259
259
|
Files: {list of files changed}
|
|
260
260
|
|
|
261
|
-
───────────────────────────────────────────────────────────────
|
|
262
261
|
|
|
263
|
-
|
|
262
|
+
|
|
263
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
264
|
+
║ ▶ NEXT UP ║
|
|
265
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
264
266
|
|
|
265
267
|
**Continue your workflow** — task complete
|
|
266
268
|
|
|
@@ -268,13 +270,13 @@ Files: {list of files changed}
|
|
|
268
270
|
|
|
269
271
|
<sub>`/clear` first → fresh context window</sub>
|
|
270
272
|
|
|
271
|
-
|
|
273
|
+
|
|
272
274
|
|
|
273
275
|
**Also available:**
|
|
274
276
|
- `/pbr:continue` — execute next logical step
|
|
275
277
|
- `/pbr:todo list` — see pending todos
|
|
276
278
|
|
|
277
|
-
|
|
279
|
+
|
|
278
280
|
```
|
|
279
281
|
|
|
280
282
|
**If partial:**
|
|
@@ -11,9 +11,9 @@ allowed-tools: Read, Write, Bash, Glob, Grep, AskUserQuestion
|
|
|
11
11
|
**Before ANY tool calls**, display this banner:
|
|
12
12
|
|
|
13
13
|
```
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
15
|
+
║ PLAN-BUILD-RUN ► RESUMING SESSION ║
|
|
16
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
17
17
|
```
|
|
18
18
|
|
|
19
19
|
Then proceed to Step 1.
|
|
@@ -147,9 +147,9 @@ Use the selected pause point for the rest of the resume flow.
|
|
|
147
147
|
3. Display the resume context using the branded banner:
|
|
148
148
|
|
|
149
149
|
```
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
150
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
151
|
+
║ PLAN-BUILD-RUN ► SESSION RESTORED ✓ ║
|
|
152
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
153
153
|
|
|
154
154
|
Resuming session from {pause date}
|
|
155
155
|
|
|
@@ -182,9 +182,11 @@ Blockers:
|
|
|
182
182
|
|
|
183
183
|
**If only one clear next action exists**, present it with branded routing:
|
|
184
184
|
```
|
|
185
|
-
───────────────────────────────────────────────────────────────
|
|
186
185
|
|
|
187
|
-
|
|
186
|
+
|
|
187
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
188
|
+
║ ▶ NEXT UP ║
|
|
189
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
188
190
|
|
|
189
191
|
**{explanation from continue-here}**
|
|
190
192
|
|
|
@@ -192,7 +194,7 @@ Blockers:
|
|
|
192
194
|
|
|
193
195
|
<sub>`/clear` first → fresh context window</sub>
|
|
194
196
|
|
|
195
|
-
|
|
197
|
+
|
|
196
198
|
```
|
|
197
199
|
|
|
198
200
|
**If multiple reasonable actions exist** (e.g., the continue-here suggests one thing but the filesystem state suggests another), use the **action-routing** pattern (see `skills/shared/gate-prompts.md`):
|
|
@@ -23,9 +23,9 @@ Additionally for this skill:
|
|
|
23
23
|
**Before ANY tool calls**, display this banner:
|
|
24
24
|
|
|
25
25
|
```
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
26
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
27
|
+
║ PLAN-BUILD-RUN ► REVIEWING PHASE {N} ║
|
|
28
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
29
29
|
```
|
|
30
30
|
|
|
31
31
|
Where `{N}` is the phase number from `$ARGUMENTS`. Then proceed to Step 1.
|
|
@@ -66,6 +66,7 @@ Execute these steps in order.
|
|
|
66
66
|
|
|
67
67
|
1. Parse `$ARGUMENTS` for phase number and `--auto-fix` flag
|
|
68
68
|
2. Read `.planning/config.json`
|
|
69
|
+
**CRITICAL: Write .active-skill NOW.** Write the text "review" to `.planning/.active-skill` using the Write tool.
|
|
69
70
|
3. Resolve depth profile: run `node ${CLAUDE_PLUGIN_ROOT}/scripts/pbr-tools.js config resolve-depth` to get the effective feature/gate settings for the current depth. Store the result for use in later gating decisions.
|
|
70
71
|
4. Validate:
|
|
71
72
|
- Phase directory exists at `.planning/phases/{NN}-{slug}/`
|
|
@@ -574,6 +575,10 @@ Ask user: "Would you like to proceed with gap-closure plans without root cause a
|
|
|
574
575
|
|
|
575
576
|
---
|
|
576
577
|
|
|
578
|
+
## Cleanup
|
|
579
|
+
|
|
580
|
+
Delete `.planning/.active-skill` if it exists. This must happen on all paths (success, partial, and failure) before reporting results.
|
|
581
|
+
|
|
577
582
|
## Completion
|
|
578
583
|
|
|
579
584
|
After review completes, always present a clear next action:
|
|
@@ -582,9 +587,9 @@ After review completes, always present a clear next action:
|
|
|
582
587
|
|
|
583
588
|
Display the "Phase Complete" banner inline:
|
|
584
589
|
```
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
590
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
591
|
+
║ PLAN-BUILD-RUN ► PHASE {N} COMPLETE ✓ ║
|
|
592
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
588
593
|
|
|
589
594
|
**Phase {N}: {Name}**
|
|
590
595
|
|
|
@@ -594,9 +599,11 @@ Goal verified ✓
|
|
|
594
599
|
|
|
595
600
|
Then the branded "Next Up" block:
|
|
596
601
|
```
|
|
597
|
-
───────────────────────────────────────────────────────────────
|
|
598
602
|
|
|
599
|
-
|
|
603
|
+
|
|
604
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
605
|
+
║ ▶ NEXT UP ║
|
|
606
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
600
607
|
|
|
601
608
|
**Phase {N+1}: {Name}** — {Goal from ROADMAP.md}
|
|
602
609
|
|
|
@@ -604,26 +611,28 @@ Then the branded "Next Up" block:
|
|
|
604
611
|
|
|
605
612
|
<sub>`/clear` first → fresh context window</sub>
|
|
606
613
|
|
|
607
|
-
|
|
614
|
+
|
|
608
615
|
|
|
609
616
|
**Also available:**
|
|
610
617
|
- `/pbr:discuss {N+1}` — talk through details before planning
|
|
611
618
|
- `/pbr:status` — see full project status
|
|
612
619
|
|
|
613
|
-
|
|
620
|
+
|
|
614
621
|
```
|
|
615
622
|
|
|
616
623
|
**If gaps remain:**
|
|
617
624
|
```
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
625
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
626
|
+
║ PLAN-BUILD-RUN ► PHASE {N} GAPS FOUND ⚠ ║
|
|
627
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
621
628
|
|
|
622
629
|
**Phase {N}: {name}** — {count} gaps remaining
|
|
623
630
|
|
|
624
|
-
───────────────────────────────────────────────────────────────
|
|
625
631
|
|
|
626
|
-
|
|
632
|
+
|
|
633
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
634
|
+
║ ▶ NEXT UP ║
|
|
635
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
627
636
|
|
|
628
637
|
**Fix gaps** — diagnose and create fix plans
|
|
629
638
|
|
|
@@ -631,22 +640,22 @@ Then the branded "Next Up" block:
|
|
|
631
640
|
|
|
632
641
|
<sub>`/clear` first → fresh context window</sub>
|
|
633
642
|
|
|
634
|
-
|
|
643
|
+
|
|
635
644
|
|
|
636
645
|
**Also available:**
|
|
637
646
|
- `/pbr:plan {N} --gaps` — create fix plans manually
|
|
638
647
|
- Fix manually, then `/pbr:review {N}`
|
|
639
648
|
|
|
640
|
-
|
|
649
|
+
|
|
641
650
|
```
|
|
642
651
|
|
|
643
652
|
**If final phase:**
|
|
644
653
|
|
|
645
654
|
Display the "Milestone Complete" banner inline:
|
|
646
655
|
```
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
656
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
657
|
+
║ PLAN-BUILD-RUN ► MILESTONE COMPLETE 🎉 ║
|
|
658
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
650
659
|
|
|
651
660
|
{N} phases completed
|
|
652
661
|
All phase goals verified ✓
|
|
@@ -654,9 +663,11 @@ All phase goals verified ✓
|
|
|
654
663
|
|
|
655
664
|
Then:
|
|
656
665
|
```
|
|
657
|
-
───────────────────────────────────────────────────────────────
|
|
658
666
|
|
|
659
|
-
|
|
667
|
+
|
|
668
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
669
|
+
║ ▶ NEXT UP ║
|
|
670
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
660
671
|
|
|
661
672
|
**Audit milestone** — verify cross-phase integration
|
|
662
673
|
|
|
@@ -664,14 +675,14 @@ Then:
|
|
|
664
675
|
|
|
665
676
|
<sub>`/clear` first → fresh context window</sub>
|
|
666
677
|
|
|
667
|
-
|
|
678
|
+
|
|
668
679
|
|
|
669
680
|
**Also available:**
|
|
670
681
|
- `/pbr:milestone complete` — archive milestone after audit passes
|
|
671
682
|
- `/pbr:milestone new` — start planning next features
|
|
672
683
|
- `/pbr:status` — see final project status
|
|
673
684
|
|
|
674
|
-
|
|
685
|
+
|
|
675
686
|
```
|
|
676
687
|
|
|
677
688
|
---
|
|
@@ -11,9 +11,9 @@ allowed-tools: Read, Write, Bash, Glob, Grep, Task, AskUserQuestion
|
|
|
11
11
|
**Before ANY tool calls**, display this banner:
|
|
12
12
|
|
|
13
13
|
```
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
15
|
+
║ PLAN-BUILD-RUN ► SCANNING CODEBASE ║
|
|
16
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
17
17
|
```
|
|
18
18
|
|
|
19
19
|
Then proceed to Step 1.
|
|
@@ -180,9 +180,9 @@ Agent that failed: {focus_area} mapper
|
|
|
180
180
|
Read key findings from each file (frontmatter or first section) and display using the branded stage banner from `references/ui-formatting.md`:
|
|
181
181
|
|
|
182
182
|
```
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
183
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
184
|
+
║ PLAN-BUILD-RUN ► SCAN COMPLETE ✓ ║
|
|
185
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
186
186
|
|
|
187
187
|
Project: {type} ({scale})
|
|
188
188
|
Stack: {primary language} + {framework}
|
|
@@ -209,9 +209,11 @@ Top concerns:
|
|
|
209
209
|
|
|
210
210
|
Then use the "Next Up" routing block:
|
|
211
211
|
```
|
|
212
|
-
───────────────────────────────────────────────────────────────
|
|
213
212
|
|
|
214
|
-
|
|
213
|
+
|
|
214
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
215
|
+
║ ▶ NEXT UP ║
|
|
216
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
215
217
|
|
|
216
218
|
**Start a project** — use the scan results to plan your work
|
|
217
219
|
|
|
@@ -219,13 +221,13 @@ Then use the "Next Up" routing block:
|
|
|
219
221
|
|
|
220
222
|
<sub>`/clear` first → fresh context window</sub>
|
|
221
223
|
|
|
222
|
-
|
|
224
|
+
|
|
223
225
|
|
|
224
226
|
**Also available:**
|
|
225
227
|
- `/pbr:milestone new` — create a milestone to address concerns
|
|
226
228
|
- `/pbr:status` — see project status
|
|
227
229
|
|
|
228
|
-
|
|
230
|
+
|
|
229
231
|
```
|
|
230
232
|
|
|
231
233
|
### Step 7: Git Integration
|
|
@@ -11,9 +11,9 @@ allowed-tools: Read, Write, Bash, Glob, AskUserQuestion
|
|
|
11
11
|
**Before ANY tool calls**, display this banner:
|
|
12
12
|
|
|
13
13
|
```
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
15
|
+
║ PLAN-BUILD-RUN ► SETUP ║
|
|
16
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
17
17
|
```
|
|
18
18
|
|
|
19
19
|
Then proceed to Step 1.
|
|
@@ -24,14 +24,29 @@ You are running the **setup** skill. This is an interactive onboarding wizard th
|
|
|
24
24
|
|
|
25
25
|
---
|
|
26
26
|
|
|
27
|
-
## Step 1: Detect Project State
|
|
27
|
+
## Step 1: Detect Project State — Idempotency Guard
|
|
28
28
|
|
|
29
29
|
Check if `.planning/` directory exists in the current working directory.
|
|
30
30
|
|
|
31
31
|
**If `.planning/` exists**:
|
|
32
|
-
-
|
|
33
|
-
-
|
|
34
|
-
|
|
32
|
+
- Check for existing core files: `STATE.md`, `ROADMAP.md`, `config.json`
|
|
33
|
+
- If ANY of these exist, present a checkpoint:
|
|
34
|
+
|
|
35
|
+
Use AskUserQuestion:
|
|
36
|
+
question: "Existing project detected with {list of found files}. How should we proceed?"
|
|
37
|
+
header: "Setup"
|
|
38
|
+
options:
|
|
39
|
+
- label: "Resume" description: "Keep existing .planning/ and review configuration (recommended)"
|
|
40
|
+
- label: "Reset" description: "Archive current .planning/ to .planning.bak/ and start fresh"
|
|
41
|
+
- label: "Abort" description: "Cancel setup — keep everything as-is"
|
|
42
|
+
|
|
43
|
+
- If "Resume": Tell the user: "Keeping existing project. Reviewing configuration." Skip to Step 3 (model selection)
|
|
44
|
+
- If "Reset": Run `mv .planning .planning.bak` (creating a backup), then proceed with fresh setup below
|
|
45
|
+
- If "Abort": Display "Setup cancelled. Run `/pbr:status` to see current project state." and stop
|
|
46
|
+
|
|
47
|
+
- If `.planning/` exists but has NONE of the core files (empty or only has subdirs):
|
|
48
|
+
- Tell the user: "Found empty .planning/ directory. Proceeding with initialization."
|
|
49
|
+
- Continue to fresh setup below
|
|
35
50
|
|
|
36
51
|
**If `.planning/` does NOT exist**:
|
|
37
52
|
- Ask the user:
|
|
@@ -51,10 +66,14 @@ If "No", display: "Run `/pbr:begin` when you're ready to start a project. It inc
|
|
|
51
66
|
|
|
52
67
|
If "Yes", create the minimal `.planning/` structure:
|
|
53
68
|
|
|
69
|
+
**CRITICAL: Create .planning/ directory structure NOW. Do NOT skip this step.**
|
|
70
|
+
|
|
54
71
|
```bash
|
|
55
72
|
mkdir -p .planning/phases .planning/todos/pending .planning/todos/done .planning/logs .planning/research
|
|
56
73
|
```
|
|
57
74
|
|
|
75
|
+
**CRITICAL: Write .planning/config.json NOW. Do NOT skip this step.**
|
|
76
|
+
|
|
58
77
|
Create `.planning/config.json` with defaults:
|
|
59
78
|
```json
|
|
60
79
|
{
|
|
@@ -123,6 +142,8 @@ Create `.planning/config.json` with defaults:
|
|
|
123
142
|
}
|
|
124
143
|
```
|
|
125
144
|
|
|
145
|
+
**CRITICAL: Write .planning/STATE.md NOW. Do NOT skip this step.**
|
|
146
|
+
|
|
126
147
|
Create `.planning/STATE.md`:
|
|
127
148
|
```markdown
|
|
128
149
|
---
|
|
@@ -243,6 +264,8 @@ This project uses [Plan-Build-Run](https://github.com/SienkLogic/plan-build-run)
|
|
|
243
264
|
|
|
244
265
|
## Step 5: Verification
|
|
245
266
|
|
|
267
|
+
**CRITICAL: Run validation checks NOW to confirm setup succeeded. Do NOT skip this step.**
|
|
268
|
+
|
|
246
269
|
Run a quick health check:
|
|
247
270
|
|
|
248
271
|
1. Verify `.planning/config.json` is valid JSON
|
|
@@ -77,3 +77,5 @@ Blocked: {short reason}
|
|
|
77
77
|
```
|
|
78
78
|
|
|
79
79
|
This format is used by validate-commit.js and check-dangerous-commands.js. The `decision: "block"` and `reason` fields in the JSON output follow this pattern.
|
|
80
|
+
|
|
81
|
+
Block reasons should always include a "To fix:" line with actionable guidance so the user or agent knows how to resolve the block.
|
|
@@ -23,11 +23,15 @@ These rules prevent context rot -- quality degradation as the context window fil
|
|
|
23
23
|
8. **Never** read `.planning/logs/` files -- only the health skill reads these.
|
|
24
24
|
9. **Do not** re-read full file contents when frontmatter is sufficient -- frontmatter contains status, key_files, commits, and provides fields.
|
|
25
25
|
|
|
26
|
+
## Task/Subagent Rules (apply to every skill)
|
|
27
|
+
|
|
28
|
+
10. **Never** invoke `Skill()` inside a `Task()` subagent -- the Skill tool is not available in subagent contexts. Subagents spawned by `Task()` cannot resolve `/pbr:*` skill prefixes, so `Skill({ skill: "pbr:plan" })` will silently fail. Instead, chain skills at the orchestrator level (return control to the orchestrator, then call `Skill()` from there). For subagent work, use `subagent_type: "pbr:{agent}"` which auto-loads agent definitions.
|
|
29
|
+
|
|
26
30
|
## Behavioral Rules (apply to every skill)
|
|
27
31
|
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
32
|
+
11. **Do not** re-litigate decisions that are already locked in CONTEXT.md -- respect locked decisions unconditionally.
|
|
33
|
+
12. **Do not** create artifacts the user did not approve -- always confirm before writing new planning documents.
|
|
34
|
+
13. **Do not** modify files outside the skill's stated scope -- check the "Files Created/Modified" table in each skill.
|
|
35
|
+
14. **Do not** suggest multiple next actions without clear priority -- one primary suggestion, alternatives listed secondary.
|
|
36
|
+
15. **Do not** use `git add .` or `git add -A` -- stage specific files only.
|
|
37
|
+
16. **Do not** include sensitive information (API keys, passwords, tokens) in planning documents or commits.
|
|
@@ -11,9 +11,9 @@ allowed-tools: Read, Glob, Grep, AskUserQuestion
|
|
|
11
11
|
**Before ANY tool calls**, display this banner:
|
|
12
12
|
|
|
13
13
|
```
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
15
|
+
║ PLAN-BUILD-RUN ► PROJECT STATUS ║
|
|
16
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
17
17
|
```
|
|
18
18
|
|
|
19
19
|
Then proceed to Step 1.
|
|
@@ -268,9 +268,11 @@ Based on the project state, suggest the single most logical next action:
|
|
|
268
268
|
**If only one reasonable next action exists**, present it with branded routing:
|
|
269
269
|
|
|
270
270
|
```
|
|
271
|
-
───────────────────────────────────────────────────────────────
|
|
272
271
|
|
|
273
|
-
|
|
272
|
+
|
|
273
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
274
|
+
║ ▶ NEXT UP ║
|
|
275
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
274
276
|
|
|
275
277
|
**{brief explanation}**
|
|
276
278
|
|
|
@@ -278,7 +280,7 @@ Based on the project state, suggest the single most logical next action:
|
|
|
278
280
|
|
|
279
281
|
<sub>`/clear` first → fresh context window</sub>
|
|
280
282
|
|
|
281
|
-
|
|
283
|
+
|
|
282
284
|
```
|
|
283
285
|
|
|
284
286
|
**If multiple reasonable next actions exist** (2-3 alternatives), use the **action-routing** pattern (see `skills/shared/gate-prompts.md`):
|
|
@@ -12,9 +12,9 @@ argument-hint: "[install | uninstall | preview]"
|
|
|
12
12
|
**Before ANY tool calls**, display this banner:
|
|
13
13
|
|
|
14
14
|
```
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
15
|
+
╔══════════════════════════════════════════════════════════════╗
|
|
16
|
+
║ PLAN-BUILD-RUN ► STATUS LINE ║
|
|
17
|
+
╚══════════════════════════════════════════════════════════════╝
|
|
18
18
|
```
|
|
19
19
|
|
|
20
20
|
Then proceed to Step 1.
|
|
@@ -78,9 +78,12 @@ If "Install":
|
|
|
78
78
|
|
|
79
79
|
**CRITICAL: Use Read tool to read the file, then Write to update it. Do NOT use sed or other text manipulation on JSON files.**
|
|
80
80
|
|
|
81
|
+
**CRITICAL: Back up settings.json NOW.** Write the original content to `~/.claude/settings.json.bak` before making any changes.
|
|
82
|
+
|
|
81
83
|
1. Read `~/.claude/settings.json`
|
|
82
|
-
2.
|
|
83
|
-
3.
|
|
84
|
+
2. Write the original content to `~/.claude/settings.json.bak`
|
|
85
|
+
3. Parse the JSON
|
|
86
|
+
4. Set `statusLine` to:
|
|
84
87
|
```json
|
|
85
88
|
{
|
|
86
89
|
"type": "command",
|
|
@@ -88,7 +91,7 @@ If "Install":
|
|
|
88
91
|
}
|
|
89
92
|
```
|
|
90
93
|
Where `SCRIPT_PATH` is the resolved absolute path from Step 1. Use forward slashes even on Windows.
|
|
91
|
-
|
|
94
|
+
5. Write the updated JSON back (preserve all other settings, use 2-space indentation)
|
|
92
95
|
|
|
93
96
|
### Step 4: Verify and confirm
|
|
94
97
|
|
|
@@ -115,8 +118,9 @@ Customize per-project via .planning/config.json:
|
|
|
115
118
|
|
|
116
119
|
1. Read `~/.claude/settings.json`
|
|
117
120
|
2. If no `statusLine` key: inform user "No status line configured." and stop
|
|
118
|
-
3.
|
|
119
|
-
4.
|
|
121
|
+
3. **CRITICAL: Back up settings.json NOW.** Write the original content to `~/.claude/settings.json.bak` before making any changes.
|
|
122
|
+
4. Remove the `statusLine` key from the JSON
|
|
123
|
+
5. Write the updated file
|
|
120
124
|
5. Display: `✓ PBR status line removed. Restart Claude Code to take effect.`
|
|
121
125
|
|
|
122
126
|
---
|