Claude-skill-registry gsd-execute-phase
Execute all plans in a phase with wave-based parallelization
git clone https://github.com/majiayu000/claude-skill-registry
T=$(mktemp -d) && git clone --depth=1 https://github.com/majiayu000/claude-skill-registry "$T" && mkdir -p ~/.claude/skills && cp -r "$T/skills/data/gsd-execute-phase" ~/.claude/skills/majiayu000-claude-skill-registry-gsd-execute-phase && rm -rf "$T"
skills/data/gsd-execute-phase/SKILL.mdOrchestrator stays lean: discover plans, analyze dependencies, group into waves, spawn subagents, collect results. Each subagent loads the full execute-plan context and handles its own plan.
Context budget: ~15% orchestrator, 100% fresh per subagent. </objective>
<execution_context> @.github/get-shit-done/references/ui-brand.md @.github/get-shit-done/workflows/execute-phase.md </execution_context>
<context> Phase: $ARGUMENTSFlags:
— Execute only gap closure plans (plans with--gaps-only
in frontmatter). Use after verify-work creates fix plans.gap_closure: true
@.planning/ROADMAP.md @.planning/STATE.md </context>
<process> 1. **Validate phase exists** - Find phase directory matching argument - Count PLAN.md files - Error if no plans found-
Discover plans
- List all *-PLAN.md files in phase directory
- Check which have *-SUMMARY.md (already complete)
- If
: filter to only plans with--gaps-onlygap_closure: true - Build list of incomplete plans
-
Group by wave
- Read
from each plan's frontmatterwave - Group plans by wave number
- Report wave structure to user
- Read
-
Execute waves For each wave in order:
- Spawn
for each plan in wave (parallel Task calls)gsd-executor - Wait for completion (Task blocks)
- Verify SUMMARYs created
- Proceed to next wave
- Spawn
-
Aggregate results
- Collect summaries from all plans
- Report phase completion status
-
Commit any orchestrator corrections Check for uncommitted changes before verification:
git status --porcelainIf changes exist: Orchestrator made corrections between executor completions. Commit them:
git add -u && git commit -m "fix({phase}): orchestrator corrections"If clean: Continue to verification.
-
Verify phase goal
- Spawn
subagent with phase directory and goalgsd-verifier - Verifier checks must_haves against actual codebase (not SUMMARY claims)
- Creates VERIFICATION.md with detailed report
- Route by status:
→ continue to step 8passed
→ present items, get approval or feedbackhuman_needed
→ present gaps, offergaps_found/gsd-plan-phase {X} --gaps
- Spawn
-
Update roadmap and state
- Update ROADMAP.md, STATE.md
-
Update requirements Mark phase requirements as Complete:
- Read ROADMAP.md, find this phase's
line (e.g., "AUTH-01, AUTH-02")Requirements: - Read REQUIREMENTS.md traceability table
- For each REQ-ID in this phase: change Status from "Pending" to "Complete"
- Write updated REQUIREMENTS.md
- Skip if: REQUIREMENTS.md doesn't exist, or phase has no Requirements line
- Read ROADMAP.md, find this phase's
-
Commit phase completion Bundle all phase metadata updates in one commit:
- Stage:
git add .planning/ROADMAP.md .planning/STATE.md - Stage REQUIREMENTS.md if updated:
git add .planning/REQUIREMENTS.md - Commit:
docs({phase}): complete {phase-name} phase
- Stage:
-
Offer next steps
- Route to next action (see
) </process><offer_next>
- Route to next action (see
<offer_next> Output this markdown directly (not as a code block). Route based on status:
| Status | Route |
|---|---|
| Route C (gap closure) |
| Present checklist, then re-route based on approval |
+ more phases | Route A (next phase) |
+ last phase | Route B (milestone complete) |
Route A: Phase verified, more phases remain
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ GSD ► PHASE {Z} COMPLETE ✓ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Phase {Z}: {Name}
{Y} plans executed Goal verified ✓
───────────────────────────────────────────────────────────────
▶ Next Up
Phase {Z+1}: {Name} — {Goal from ROADMAP.md}
/gsd-discuss-phase {Z+1} — gather context and clarify approach
<sub>/clear first → fresh context window</sub>
───────────────────────────────────────────────────────────────
Also available:
- /gsd-plan-phase {Z+1} — skip discussion, plan directly
- /gsd-verify-work {Z} — manual acceptance testing before continuing
───────────────────────────────────────────────────────────────
Route B: Phase verified, milestone complete
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ GSD ► MILESTONE COMPLETE 🎉 ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
v1.0
{N} phases completed All phase goals verified ✓
───────────────────────────────────────────────────────────────
▶ Next Up
Audit milestone — verify requirements, cross-phase integration, E2E flows
/gsd-audit-milestone
<sub>/clear first → fresh context window</sub>
───────────────────────────────────────────────────────────────
Also available:
- /gsd-verify-work — manual acceptance testing
- /gsd-complete-milestone — skip audit, archive directly
───────────────────────────────────────────────────────────────
Route C: Gaps found — need additional planning
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ GSD ► PHASE {Z} GAPS FOUND ⚠ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Phase {Z}: {Name}
Score: {N}/{M} must-haves verified Report: .planning/phases/{phase_dir}/{phase}-VERIFICATION.md
What's Missing
{Extract gap summaries from VERIFICATION.md}
───────────────────────────────────────────────────────────────
▶ Next Up
Plan gap closure — create additional plans to complete the phase
/gsd-plan-phase {Z} --gaps
<sub>/clear first → fresh context window</sub>
───────────────────────────────────────────────────────────────
Also available:
- cat .planning/phases/{phase_dir}/{phase}-VERIFICATION.md — see full report
- /gsd-verify-work {Z} — manual testing before planning
───────────────────────────────────────────────────────────────
After user runs /gsd-plan-phase {Z} --gaps:
- Planner reads VERIFICATION.md gaps
- Creates plans 04, 05, etc. to close gaps
- User runs /gsd-execute-phase {Z} again
- Execute-phase runs incomplete plans (04, 05...)
- Verifier runs again → loop until passed </offer_next>
<wave_execution> Parallel spawning:
Spawn all plans in a wave with a single message containing multiple Task calls:
Task(prompt="Execute plan at {plan_01_path}\n\nPlan: @{plan_01_path}\nProject state: @.planning/STATE.md", subagent_type="gsd-executor") Task(prompt="Execute plan at {plan_02_path}\n\nPlan: @{plan_02_path}\nProject state: @.planning/STATE.md", subagent_type="gsd-executor") Task(prompt="Execute plan at {plan_03_path}\n\nPlan: @{plan_03_path}\nProject state: @.planning/STATE.md", subagent_type="gsd-executor")
All three run in parallel. Task tool blocks until all complete.
No polling. No background agents. No TaskOutput loops. </wave_execution>
<checkpoint_handling> Plans with
autonomous: false have checkpoints. The execute-phase.md workflow handles the full checkpoint flow:
- Subagent pauses at checkpoint, returns structured state
- Orchestrator presents to user, collects response
- Spawns fresh continuation agent (not resume)
See
@.github/get-shit-done/workflows/execute-phase.md step checkpoint_handling for complete details.
</checkpoint_handling>
<deviation_rules> During execution, handle discoveries automatically:
- Auto-fix bugs - Fix immediately, document in Summary
- Auto-add critical - Security/correctness gaps, add and document
- Auto-fix blockers - Can't proceed without fix, do it and document
- Ask about architectural - Major structural changes, stop and ask user
Only rule 4 requires user intervention. </deviation_rules>
<commit_rules> Per-Task Commits:
After each task completes:
- Stage only files modified by that task
- Commit with format:
{type}({phase}-{plan}): {task-name} - Types: feat, fix, test, refactor, perf, chore
- Record commit hash for SUMMARY.md
Plan Metadata Commit:
After all tasks in a plan complete:
- Stage plan artifacts only: PLAN.md, SUMMARY.md
- Commit with format:
docs({phase}-{plan}): complete [plan-name] plan - NO code files (already committed per-task)
Phase Completion Commit:
After all plans in phase complete (step 7):
- Stage: ROADMAP.md, STATE.md, REQUIREMENTS.md (if updated), VERIFICATION.md
- Commit with format:
docs({phase}): complete {phase-name} phase - Bundles all phase-level state updates in one commit
NEVER use:
git add .git add -A
or any broad directorygit add src/
Always stage files individually. </commit_rules>
<success_criteria>
- All incomplete plans in phase executed
- Each plan has SUMMARY.md
- Phase goal verified (must_haves checked against codebase)
- VERIFICATION.md created in phase directory
- STATE.md reflects phase completion
- ROADMAP.md updated
- REQUIREMENTS.md updated (phase requirements marked Complete)
- User informed of next steps </success_criteria>