@undeemed/get-shit-done-codex 1.6.12 → 1.20.3

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.
Files changed (114) hide show
  1. package/README.md +40 -7
  2. package/agents/gsd-codebase-mapper.md +761 -0
  3. package/agents/gsd-debugger.md +1198 -0
  4. package/agents/gsd-executor.md +419 -0
  5. package/agents/gsd-integration-checker.md +423 -0
  6. package/agents/gsd-phase-researcher.md +469 -0
  7. package/agents/gsd-plan-checker.md +622 -0
  8. package/agents/gsd-planner.md +1159 -0
  9. package/agents/gsd-project-researcher.md +618 -0
  10. package/agents/gsd-research-synthesizer.md +236 -0
  11. package/agents/gsd-roadmapper.md +639 -0
  12. package/agents/gsd-verifier.md +541 -0
  13. package/bin/install.js +108 -102
  14. package/commands/gsd/add-phase.md +17 -185
  15. package/commands/gsd/add-todo.md +23 -163
  16. package/commands/gsd/audit-milestone.md +3 -219
  17. package/commands/gsd/check-todos.md +20 -196
  18. package/commands/gsd/cleanup.md +18 -0
  19. package/commands/gsd/complete-milestone.md +2 -2
  20. package/commands/gsd/debug.md +13 -0
  21. package/commands/gsd/discuss-phase.md +13 -6
  22. package/commands/gsd/execute-phase.md +4 -266
  23. package/commands/gsd/health.md +22 -0
  24. package/commands/gsd/help.md +8 -369
  25. package/commands/gsd/insert-phase.md +9 -203
  26. package/commands/gsd/join-discord.md +18 -0
  27. package/commands/gsd/list-phase-assumptions.md +4 -4
  28. package/commands/gsd/map-codebase.md +1 -1
  29. package/commands/gsd/new-milestone.md +16 -682
  30. package/commands/gsd/new-project.md +12 -866
  31. package/commands/gsd/new-project.md.bak +1041 -0
  32. package/commands/gsd/pause-work.md +17 -105
  33. package/commands/gsd/plan-milestone-gaps.md +3 -247
  34. package/commands/gsd/plan-phase.md +13 -444
  35. package/commands/gsd/progress.md +5 -337
  36. package/commands/gsd/quick.md +40 -0
  37. package/commands/gsd/reapply-patches.md +110 -0
  38. package/commands/gsd/remove-phase.md +9 -315
  39. package/commands/gsd/research-phase.md +27 -20
  40. package/commands/gsd/resume-work.md +2 -2
  41. package/commands/gsd/set-profile.md +34 -0
  42. package/commands/gsd/settings.md +36 -0
  43. package/commands/gsd/update.md +25 -160
  44. package/commands/gsd/verify-work.md +6 -186
  45. package/get-shit-done/bin/gsd-tools.cjs +5243 -0
  46. package/get-shit-done/bin/gsd-tools.test.cjs +2273 -0
  47. package/get-shit-done/references/checkpoints.md +270 -283
  48. package/get-shit-done/references/decimal-phase-calculation.md +65 -0
  49. package/get-shit-done/references/git-integration.md +7 -13
  50. package/get-shit-done/references/git-planning-commit.md +38 -0
  51. package/get-shit-done/references/model-profile-resolution.md +34 -0
  52. package/get-shit-done/references/model-profiles.md +92 -0
  53. package/get-shit-done/references/phase-argument-parsing.md +61 -0
  54. package/get-shit-done/references/planning-config.md +196 -0
  55. package/get-shit-done/references/questioning.md +5 -1
  56. package/get-shit-done/references/verification-patterns.md +17 -0
  57. package/get-shit-done/templates/DEBUG.md +4 -4
  58. package/get-shit-done/templates/UAT.md +1 -1
  59. package/get-shit-done/templates/codebase/architecture.md +1 -1
  60. package/get-shit-done/templates/codebase/concerns.md +1 -1
  61. package/get-shit-done/templates/codebase/conventions.md +1 -1
  62. package/get-shit-done/templates/codebase/structure.md +9 -9
  63. package/get-shit-done/templates/config.json +10 -0
  64. package/get-shit-done/templates/context.md +7 -15
  65. package/get-shit-done/templates/continue-here.md +1 -1
  66. package/get-shit-done/templates/phase-prompt.md +32 -41
  67. package/get-shit-done/templates/planner-subagent-prompt.md +4 -4
  68. package/get-shit-done/templates/project.md +1 -1
  69. package/get-shit-done/templates/research-project/ARCHITECTURE.md +1 -1
  70. package/get-shit-done/templates/research.md +27 -4
  71. package/get-shit-done/templates/state.md +1 -31
  72. package/get-shit-done/templates/summary-complex.md +59 -0
  73. package/get-shit-done/templates/summary-minimal.md +41 -0
  74. package/get-shit-done/templates/summary-standard.md +48 -0
  75. package/get-shit-done/templates/summary.md +5 -28
  76. package/get-shit-done/templates/user-setup.md +8 -20
  77. package/get-shit-done/templates/verification-report.md +3 -3
  78. package/get-shit-done/workflows/add-phase.md +111 -0
  79. package/get-shit-done/workflows/add-todo.md +157 -0
  80. package/get-shit-done/workflows/audit-milestone.md +242 -0
  81. package/get-shit-done/workflows/check-todos.md +176 -0
  82. package/get-shit-done/workflows/cleanup.md +152 -0
  83. package/get-shit-done/workflows/complete-milestone.md +225 -301
  84. package/get-shit-done/workflows/diagnose-issues.md +3 -17
  85. package/get-shit-done/workflows/discovery-phase.md +11 -15
  86. package/get-shit-done/workflows/discuss-phase.md +105 -42
  87. package/get-shit-done/workflows/execute-phase.md +205 -349
  88. package/get-shit-done/workflows/execute-plan.md +179 -1569
  89. package/get-shit-done/workflows/health.md +156 -0
  90. package/get-shit-done/workflows/help.md +486 -0
  91. package/get-shit-done/workflows/insert-phase.md +129 -0
  92. package/get-shit-done/workflows/list-phase-assumptions.md +9 -9
  93. package/get-shit-done/workflows/map-codebase.md +56 -18
  94. package/get-shit-done/workflows/new-milestone.md +373 -0
  95. package/get-shit-done/workflows/new-project.md +1113 -0
  96. package/get-shit-done/workflows/pause-work.md +122 -0
  97. package/get-shit-done/workflows/plan-milestone-gaps.md +256 -0
  98. package/get-shit-done/workflows/plan-phase.md +448 -0
  99. package/get-shit-done/workflows/progress.md +393 -0
  100. package/get-shit-done/workflows/quick.md +444 -0
  101. package/get-shit-done/workflows/remove-phase.md +154 -0
  102. package/get-shit-done/workflows/research-phase.md +74 -0
  103. package/get-shit-done/workflows/resume-project.md +18 -23
  104. package/get-shit-done/workflows/set-profile.md +80 -0
  105. package/get-shit-done/workflows/settings.md +200 -0
  106. package/get-shit-done/workflows/transition.md +78 -103
  107. package/get-shit-done/workflows/update.md +214 -0
  108. package/get-shit-done/workflows/verify-phase.md +109 -496
  109. package/get-shit-done/workflows/verify-work.md +22 -15
  110. package/hooks/dist/gsd-check-update.js +66 -0
  111. package/hooks/dist/gsd-statusline.js +91 -0
  112. package/package.json +19 -3
  113. package/scripts/build-hooks.js +42 -0
  114. package/commands/gsd/whats-new.md +0 -124
@@ -7,26 +7,27 @@ Use this workflow when:
7
7
  </trigger>
8
8
 
9
9
  <purpose>
10
- Instantly restore full project context and present clear status.
11
- Enables seamless session continuity for fully autonomous workflows.
12
-
13
- "Where were we?" should have an immediate, complete answer.
10
+ Instantly restore full project context so "Where were we?" has an immediate, complete answer.
14
11
  </purpose>
15
12
 
13
+ <required_reading>
14
+ @~/.codex/get-shit-done/references/continuation-format.md
15
+ </required_reading>
16
+
16
17
  <process>
17
18
 
18
- <step name="detect_existing_project">
19
- Check if this is an existing project:
19
+ <step name="initialize">
20
+ Load all context in one call:
20
21
 
21
22
  ```bash
22
- ls .planning/STATE.md 2>/dev/null && echo "Project exists"
23
- ls .planning/ROADMAP.md 2>/dev/null && echo "Roadmap exists"
24
- ls .planning/PROJECT.md 2>/dev/null && echo "Project file exists"
23
+ INIT=$(node ~/.codex/get-shit-done/bin/gsd-tools.cjs init resume)
25
24
  ```
26
25
 
27
- **If STATE.md exists:** Proceed to load_state
28
- **If only ROADMAP.md/PROJECT.md exist:** Offer to reconstruct STATE.md
29
- **If .planning/ doesn't exist:** This is a new project - route to /gsd:new-project
26
+ Parse JSON for: `state_exists`, `roadmap_exists`, `project_exists`, `planning_exists`, `has_interrupted_agent`, `interrupted_agent_id`, `commit_docs`.
27
+
28
+ **If `state_exists` is true:** Proceed to load_state
29
+ **If `state_exists` is false but `roadmap_exists` or `project_exists` is true:** Offer to reconstruct STATE.md
30
+ **If `planning_exists` is false:** This is a new project - route to /gsd:new-project
30
31
  </step>
31
32
 
32
33
  <step name="load_state">
@@ -70,10 +71,9 @@ for plan in .planning/phases/*/*-PLAN.md; do
70
71
  [ ! -f "$summary" ] && echo "Incomplete: $plan"
71
72
  done 2>/dev/null
72
73
 
73
- # Check for interrupted agents
74
- if [ -f .planning/current-agent-id.txt ] && [ -s .planning/current-agent-id.txt ]; then
75
- AGENT_ID=$(cat .planning/current-agent-id.txt | tr -d '\n')
76
- echo "Interrupted agent: $AGENT_ID"
74
+ # Check for interrupted agents (use has_interrupted_agent and interrupted_agent_id from init)
75
+ if [ "$has_interrupted_agent" = "true" ]; then
76
+ echo "Interrupted agent: $interrupted_agent_id"
77
77
  fi
78
78
  ```
79
79
 
@@ -196,7 +196,7 @@ What would you like to do?
196
196
  **Note:** When offering phase planning, check for CONTEXT.md existence first:
197
197
 
198
198
  ```bash
199
- ls .planning/phases/XX-name/CONTEXT.md 2>/dev/null
199
+ ls .planning/phases/XX-name/*-CONTEXT.md 2>/dev/null
200
200
  ```
201
201
 
202
202
  If missing, suggest discuss-phase before plan. If exists, offer plan directly.
@@ -286,17 +286,12 @@ This handles cases where:
286
286
  </reconstruction>
287
287
 
288
288
  <quick_resume>
289
- For users who want minimal friction:
290
-
291
- If user says just "continue" or "go":
292
-
289
+ If user says "continue" or "go":
293
290
  - Load state silently
294
291
  - Determine primary action
295
292
  - Execute immediately without presenting options
296
293
 
297
294
  "Continuing from [state]... [action]"
298
-
299
- This enables fully autonomous "just keep going" workflow.
300
295
  </quick_resume>
301
296
 
302
297
  <success_criteria>
@@ -0,0 +1,80 @@
1
+ <purpose>
2
+ Switch the model profile used by GSD agents. Controls which Codex model each agent uses, balancing quality vs token spend.
3
+ </purpose>
4
+
5
+ <required_reading>
6
+ Read all files referenced by the invoking prompt's execution_context before starting.
7
+ </required_reading>
8
+
9
+ <process>
10
+
11
+ <step name="validate">
12
+ Validate argument:
13
+
14
+ ```
15
+ if $ARGUMENTS.profile not in ["quality", "balanced", "budget"]:
16
+ Error: Invalid profile "$ARGUMENTS.profile"
17
+ Valid profiles: quality, balanced, budget
18
+ EXIT
19
+ ```
20
+ </step>
21
+
22
+ <step name="ensure_and_load_config">
23
+ Ensure config exists and load current state:
24
+
25
+ ```bash
26
+ node ~/.codex/get-shit-done/bin/gsd-tools.cjs config-ensure-section
27
+ INIT=$(node ~/.codex/get-shit-done/bin/gsd-tools.cjs state load)
28
+ ```
29
+
30
+ This creates `.planning/config.json` with defaults if missing and loads current config.
31
+ </step>
32
+
33
+ <step name="update_config">
34
+ Read current config from state load or directly:
35
+
36
+ Update `model_profile` field:
37
+ ```json
38
+ {
39
+ "model_profile": "$ARGUMENTS.profile"
40
+ }
41
+ ```
42
+
43
+ Write updated config back to `.planning/config.json`.
44
+ </step>
45
+
46
+ <step name="confirm">
47
+ Display confirmation with model table for selected profile:
48
+
49
+ ```
50
+ ✓ Model profile set to: $ARGUMENTS.profile
51
+
52
+ Agents will now use:
53
+
54
+ [Show table from MODEL_PROFILES in gsd-tools.cjs for selected profile]
55
+
56
+ Example:
57
+ | Agent | Model |
58
+ |-------|-------|
59
+ | gsd-planner | opus |
60
+ | gsd-executor | sonnet |
61
+ | gsd-verifier | haiku |
62
+ | ... | ... |
63
+
64
+ Next spawned agents will use the new profile.
65
+ ```
66
+
67
+ Map profile names:
68
+ - quality: use "quality" column from MODEL_PROFILES
69
+ - balanced: use "balanced" column from MODEL_PROFILES
70
+ - budget: use "budget" column from MODEL_PROFILES
71
+ </step>
72
+
73
+ </process>
74
+
75
+ <success_criteria>
76
+ - [ ] Argument validated
77
+ - [ ] Config file ensured
78
+ - [ ] Config updated with new model_profile
79
+ - [ ] Confirmation displayed with model table
80
+ </success_criteria>
@@ -0,0 +1,200 @@
1
+ <purpose>
2
+ Interactive configuration of GSD workflow agents (research, plan_check, verifier) and model profile selection via multi-question prompt. Updates .planning/config.json with user preferences. Optionally saves settings as global defaults (~/.gsd/defaults.json) for future projects.
3
+ </purpose>
4
+
5
+ <required_reading>
6
+ Read all files referenced by the invoking prompt's execution_context before starting.
7
+ </required_reading>
8
+
9
+ <process>
10
+
11
+ <step name="ensure_and_load_config">
12
+ Ensure config exists and load current state:
13
+
14
+ ```bash
15
+ node ~/.codex/get-shit-done/bin/gsd-tools.cjs config-ensure-section
16
+ INIT=$(node ~/.codex/get-shit-done/bin/gsd-tools.cjs state load)
17
+ ```
18
+
19
+ Creates `.planning/config.json` with defaults if missing and loads current config values.
20
+ </step>
21
+
22
+ <step name="read_current">
23
+ ```bash
24
+ cat .planning/config.json
25
+ ```
26
+
27
+ Parse current values (default to `true` if not present):
28
+ - `workflow.research` — spawn researcher during plan-phase
29
+ - `workflow.plan_check` — spawn plan checker during plan-phase
30
+ - `workflow.verifier` — spawn verifier during execute-phase
31
+ - `model_profile` — which model each agent uses (default: `balanced`)
32
+ - `git.branching_strategy` — branching approach (default: `"none"`)
33
+ </step>
34
+
35
+ <step name="present_settings">
36
+ Use AskUserQuestion with current values pre-selected:
37
+
38
+ ```
39
+ AskUserQuestion([
40
+ {
41
+ question: "Which model profile for agents?",
42
+ header: "Model",
43
+ multiSelect: false,
44
+ options: [
45
+ { label: "Quality", description: "Opus everywhere except verification (highest cost)" },
46
+ { label: "Balanced (Recommended)", description: "Opus for planning, Sonnet for execution/verification" },
47
+ { label: "Budget", description: "Sonnet for writing, Haiku for research/verification (lowest cost)" }
48
+ ]
49
+ },
50
+ {
51
+ question: "Spawn Plan Researcher? (researches domain before planning)",
52
+ header: "Research",
53
+ multiSelect: false,
54
+ options: [
55
+ { label: "Yes", description: "Research phase goals before planning" },
56
+ { label: "No", description: "Skip research, plan directly" }
57
+ ]
58
+ },
59
+ {
60
+ question: "Spawn Plan Checker? (verifies plans before execution)",
61
+ header: "Plan Check",
62
+ multiSelect: false,
63
+ options: [
64
+ { label: "Yes", description: "Verify plans meet phase goals" },
65
+ { label: "No", description: "Skip plan verification" }
66
+ ]
67
+ },
68
+ {
69
+ question: "Spawn Execution Verifier? (verifies phase completion)",
70
+ header: "Verifier",
71
+ multiSelect: false,
72
+ options: [
73
+ { label: "Yes", description: "Verify must-haves after execution" },
74
+ { label: "No", description: "Skip post-execution verification" }
75
+ ]
76
+ },
77
+ {
78
+ question: "Auto-advance pipeline? (discuss → plan → execute automatically)",
79
+ header: "Auto",
80
+ multiSelect: false,
81
+ options: [
82
+ { label: "No (Recommended)", description: "Manual /clear + paste between stages" },
83
+ { label: "Yes", description: "Chain stages via Task() subagents (same isolation)" }
84
+ ]
85
+ },
86
+ {
87
+ question: "Git branching strategy?",
88
+ header: "Branching",
89
+ multiSelect: false,
90
+ options: [
91
+ { label: "None (Recommended)", description: "Commit directly to current branch" },
92
+ { label: "Per Phase", description: "Create branch for each phase (gsd/phase-{N}-{name})" },
93
+ { label: "Per Milestone", description: "Create branch for entire milestone (gsd/{version}-{name})" }
94
+ ]
95
+ }
96
+ ])
97
+ ```
98
+ </step>
99
+
100
+ <step name="update_config">
101
+ Merge new settings into existing config.json:
102
+
103
+ ```json
104
+ {
105
+ ...existing_config,
106
+ "model_profile": "quality" | "balanced" | "budget",
107
+ "workflow": {
108
+ "research": true/false,
109
+ "plan_check": true/false,
110
+ "verifier": true/false,
111
+ "auto_advance": true/false
112
+ },
113
+ "git": {
114
+ "branching_strategy": "none" | "phase" | "milestone"
115
+ }
116
+ }
117
+ ```
118
+
119
+ Write updated config to `.planning/config.json`.
120
+ </step>
121
+
122
+ <step name="save_as_defaults">
123
+ Ask whether to save these settings as global defaults for future projects:
124
+
125
+ ```
126
+ AskUserQuestion([
127
+ {
128
+ question: "Save these as default settings for all new projects?",
129
+ header: "Defaults",
130
+ multiSelect: false,
131
+ options: [
132
+ { label: "Yes", description: "New projects start with these settings (saved to ~/.gsd/defaults.json)" },
133
+ { label: "No", description: "Only apply to this project" }
134
+ ]
135
+ }
136
+ ])
137
+ ```
138
+
139
+ If "Yes": write the same config object (minus project-specific fields like `brave_search`) to `~/.gsd/defaults.json`:
140
+
141
+ ```bash
142
+ mkdir -p ~/.gsd
143
+ ```
144
+
145
+ Write `~/.gsd/defaults.json` with:
146
+ ```json
147
+ {
148
+ "mode": <current>,
149
+ "depth": <current>,
150
+ "model_profile": <current>,
151
+ "commit_docs": <current>,
152
+ "parallelization": <current>,
153
+ "branching_strategy": <current>,
154
+ "workflow": {
155
+ "research": <current>,
156
+ "plan_check": <current>,
157
+ "verifier": <current>,
158
+ "auto_advance": <current>
159
+ }
160
+ }
161
+ ```
162
+ </step>
163
+
164
+ <step name="confirm">
165
+ Display:
166
+
167
+ ```
168
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
169
+ GSD ► SETTINGS UPDATED
170
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
171
+
172
+ | Setting | Value |
173
+ |----------------------|-------|
174
+ | Model Profile | {quality/balanced/budget} |
175
+ | Plan Researcher | {On/Off} |
176
+ | Plan Checker | {On/Off} |
177
+ | Execution Verifier | {On/Off} |
178
+ | Auto-Advance | {On/Off} |
179
+ | Git Branching | {None/Per Phase/Per Milestone} |
180
+ | Saved as Defaults | {Yes/No} |
181
+
182
+ These settings apply to future /gsd:plan-phase and /gsd:execute-phase runs.
183
+
184
+ Quick commands:
185
+ - /gsd:set-profile <profile> — switch model profile
186
+ - /gsd:plan-phase --research — force research
187
+ - /gsd:plan-phase --skip-research — skip research
188
+ - /gsd:plan-phase --skip-verify — skip plan check
189
+ ```
190
+ </step>
191
+
192
+ </process>
193
+
194
+ <success_criteria>
195
+ - [ ] Current config read
196
+ - [ ] User presented with 6 settings (profile + 4 workflow toggles + git branching)
197
+ - [ ] Config updated with model_profile, workflow, and git sections
198
+ - [ ] User offered to save as global defaults (~/.gsd/defaults.json)
199
+ - [ ] Changes confirmed to user
200
+ </success_criteria>
@@ -118,39 +118,22 @@ If found, delete them — phase is complete, handoffs are stale.
118
118
 
119
119
  </step>
120
120
 
121
- <step name="update_roadmap">
121
+ <step name="update_roadmap_and_state">
122
122
 
123
- Update the roadmap file:
123
+ **Delegate ROADMAP.md and STATE.md updates to gsd-tools:**
124
124
 
125
125
  ```bash
126
- ROADMAP_FILE=".planning/ROADMAP.md"
126
+ TRANSITION=$(node ~/.codex/get-shit-done/bin/gsd-tools.cjs phase complete "${current_phase}")
127
127
  ```
128
128
 
129
- Update the file:
129
+ The CLI handles:
130
+ - Marking the phase checkbox as `[x]` complete with today's date
131
+ - Updating plan count to final (e.g., "3/3 plans complete")
132
+ - Updating the Progress table (Status → Complete, adding date)
133
+ - Advancing STATE.md to next phase (Current Phase, Status → Ready to plan, Current Plan → Not started)
134
+ - Detecting if this is the last phase in the milestone
130
135
 
131
- - Mark current phase: `[x] Complete`
132
- - Add completion date
133
- - Update plan count to final (e.g., "3/3 plans complete")
134
- - Update Progress table
135
- - Keep next phase as `[ ] Not started`
136
-
137
- **Example:**
138
-
139
- ```markdown
140
- ## Phases
141
-
142
- - [x] Phase 1: Foundation (completed 2025-01-15)
143
- - [ ] Phase 2: Authentication ← Next
144
- - [ ] Phase 3: Core Features
145
-
146
- ## Progress
147
-
148
- | Phase | Plans Complete | Status | Completed |
149
- | ----------------- | -------------- | ----------- | ---------- |
150
- | 1. Foundation | 3/3 | Complete | 2025-01-15 |
151
- | 2. Authentication | 0/2 | Not started | - |
152
- | 3. Core Features | 0/1 | Not started | - |
153
- ```
136
+ Extract from result: `completed_phase`, `plans_executed`, `next_phase`, `next_phase_name`, `is_last_phase`.
154
137
 
155
138
  </step>
156
139
 
@@ -250,61 +233,21 @@ After (Phase 2 shipped JWT auth, discovered rate limiting needed):
250
233
 
251
234
  <step name="update_current_position_after_transition">
252
235
 
253
- Update Current Position section in STATE.md to reflect phase completion and transition.
254
-
255
- **Format:**
256
-
257
- ```markdown
258
- Phase: [next] of [total] ([Next phase name])
259
- Plan: Not started
260
- Status: Ready to plan
261
- Last activity: [today] — Phase [X] complete, transitioned to Phase [X+1]
262
-
263
- Progress: [updated progress bar]
264
- ```
265
-
266
- **Instructions:**
267
-
268
- - Increment phase number to next phase
269
- - Reset plan to "Not started"
270
- - Set status to "Ready to plan"
271
- - Update last activity to describe transition
272
- - Recalculate progress bar based on completed plans
273
-
274
- **Example — transitioning from Phase 2 to Phase 3:**
275
-
276
- Before:
277
-
278
- ```markdown
279
- ## Current Position
236
+ **Note:** Basic position updates (Current Phase, Status, Current Plan, Last Activity) were already handled by `gsd-tools phase complete` in the update_roadmap_and_state step.
280
237
 
281
- Phase: 2 of 4 (Authentication)
282
- Plan: 2 of 2 in current phase
283
- Status: Phase complete
284
- Last activity: 2025-01-20 — Completed 02-02-PLAN.md
238
+ Verify the updates are correct by reading STATE.md. If the progress bar needs updating, use:
285
239
 
286
- Progress: ███████░░░ 60%
240
+ ```bash
241
+ PROGRESS=$(node ~/.codex/get-shit-done/bin/gsd-tools.cjs progress bar --raw)
287
242
  ```
288
243
 
289
- After:
290
-
291
- ```markdown
292
- ## Current Position
293
-
294
- Phase: 3 of 4 (Core Features)
295
- Plan: Not started
296
- Status: Ready to plan
297
- Last activity: 2025-01-20 — Phase 2 complete, transitioned to Phase 3
298
-
299
- Progress: ███████░░░ 60%
300
- ```
244
+ Update the progress bar line in STATE.md with the result.
301
245
 
302
246
  **Step complete when:**
303
247
 
304
- - [ ] Phase number incremented to next phase
305
- - [ ] Plan status reset to "Not started"
306
- - [ ] Status shows "Ready to plan"
307
- - [ ] Last activity describes the transition
248
+ - [ ] Phase number incremented to next phase (done by phase complete)
249
+ - [ ] Plan status reset to "Not started" (done by phase complete)
250
+ - [ ] Status shows "Ready to plan" (done by phase complete)
308
251
  - [ ] Progress bar reflects total completed plans
309
252
 
310
253
  </step>
@@ -394,26 +337,20 @@ Resume file: None
394
337
 
395
338
  **MANDATORY: Verify milestone status before presenting next steps.**
396
339
 
397
- **Step 1: Read ROADMAP.md and identify phases in current milestone**
340
+ **Use the transition result from `gsd-tools phase complete`:**
398
341
 
399
- Read the ROADMAP.md file and extract:
400
- 1. Current phase number (the phase just transitioned from)
401
- 2. All phase numbers in the current milestone section
342
+ The `is_last_phase` field from the phase complete result tells you directly:
343
+ - `is_last_phase: false` More phases remain Go to **Route A**
344
+ - `is_last_phase: true` Milestone complete Go to **Route B**
402
345
 
403
- To find phases, look for:
404
- - Phase headers: lines starting with `### Phase` or `#### Phase`
405
- - Phase list items: lines like `- [ ] **Phase X:` or `- [x] **Phase X:`
346
+ The `next_phase` and `next_phase_name` fields give you the next phase details.
406
347
 
407
- Count total phases and identify the highest phase number in the milestone.
408
-
409
- State: "Current phase is {X}. Milestone has {N} phases (highest: {Y})."
410
-
411
- **Step 2: Route based on milestone status**
348
+ If you need additional context, use:
349
+ ```bash
350
+ ROADMAP=$(node ~/.codex/get-shit-done/bin/gsd-tools.cjs roadmap analyze)
351
+ ```
412
352
 
413
- | Condition | Meaning | Action |
414
- |-----------|---------|--------|
415
- | current phase < highest phase | More phases remain | Go to **Route A** |
416
- | current phase = highest phase | Milestone complete | Go to **Route B** |
353
+ This returns all phases with goals, disk status, and completion info.
417
354
 
418
355
  ---
419
356
 
@@ -421,10 +358,18 @@ State: "Current phase is {X}. Milestone has {N} phases (highest: {Y})."
421
358
 
422
359
  Read ROADMAP.md to get the next phase's name and goal.
423
360
 
361
+ **Check if next phase has CONTEXT.md:**
362
+
363
+ ```bash
364
+ ls .planning/phases/*[X+1]*/*-CONTEXT.md 2>/dev/null
365
+ ```
366
+
424
367
  **If next phase exists:**
425
368
 
426
369
  <if mode="yolo">
427
370
 
371
+ **If CONTEXT.md exists:**
372
+
428
373
  ```
429
374
  Phase [X] marked complete.
430
375
 
@@ -433,12 +378,26 @@ Next: Phase [X+1] — [Name]
433
378
  ⚡ Auto-continuing: Plan Phase [X+1] in detail
434
379
  ```
435
380
 
436
- Exit skill and invoke SlashCommand("/gsd:plan-phase [X+1]")
381
+ Exit skill and invoke SlashCommand("/gsd:plan-phase [X+1] --auto")
382
+
383
+ **If CONTEXT.md does NOT exist:**
384
+
385
+ ```
386
+ Phase [X] marked complete.
387
+
388
+ Next: Phase [X+1] — [Name]
389
+
390
+ ⚡ Auto-continuing: Discuss Phase [X+1] first
391
+ ```
392
+
393
+ Exit skill and invoke SlashCommand("/gsd:discuss-phase [X+1] --auto")
437
394
 
438
395
  </if>
439
396
 
440
397
  <if mode="interactive" OR="custom with gates.confirm_transition true">
441
398
 
399
+ **If CONTEXT.md does NOT exist:**
400
+
442
401
  ```
443
402
  ## ✓ Phase [X] Complete
444
403
 
@@ -448,6 +407,31 @@ Exit skill and invoke SlashCommand("/gsd:plan-phase [X+1]")
448
407
 
449
408
  **Phase [X+1]: [Name]** — [Goal from ROADMAP.md]
450
409
 
410
+ `/gsd:discuss-phase [X+1]` — gather context and clarify approach
411
+
412
+ <sub>`/clear` first → fresh context window</sub>
413
+
414
+ ---
415
+
416
+ **Also available:**
417
+ - `/gsd:plan-phase [X+1]` — skip discussion, plan directly
418
+ - `/gsd:research-phase [X+1]` — investigate unknowns
419
+
420
+ ---
421
+ ```
422
+
423
+ **If CONTEXT.md exists:**
424
+
425
+ ```
426
+ ## ✓ Phase [X] Complete
427
+
428
+ ---
429
+
430
+ ## ▶ Next Up
431
+
432
+ **Phase [X+1]: [Name]** — [Goal from ROADMAP.md]
433
+ <sub>✓ Context gathered, ready to plan</sub>
434
+
451
435
  `/gsd:plan-phase [X+1]`
452
436
 
453
437
  <sub>`/clear` first → fresh context window</sub>
@@ -455,9 +439,8 @@ Exit skill and invoke SlashCommand("/gsd:plan-phase [X+1]")
455
439
  ---
456
440
 
457
441
  **Also available:**
458
- - `/gsd:discuss-phase [X+1]` — gather context first
442
+ - `/gsd:discuss-phase [X+1]` — revisit context
459
443
  - `/gsd:research-phase [X+1]` — investigate unknowns
460
- - Review roadmap
461
444
 
462
445
  ---
463
446
  ```
@@ -514,15 +497,7 @@ Exit skill and invoke SlashCommand("/gsd:complete-milestone {version}")
514
497
  </process>
515
498
 
516
499
  <implicit_tracking>
517
-
518
- Progress tracking is IMPLICIT:
519
-
520
- - "Plan phase 2" → Phase 1 must be done (or ask)
521
- - "Plan phase 3" → Phases 1-2 must be done (or ask)
522
- - Transition workflow makes it explicit in ROADMAP.md
523
-
524
- No separate "update progress" step. Forward motion IS progress.
525
-
500
+ Progress tracking is IMPLICIT: planning phase N implies phases 1-(N-1) complete. No separate progress step—forward motion IS progress.
526
501
  </implicit_tracking>
527
502
 
528
503
  <partial_completion>