From 402dd2872bab71c043809568cd6fe7ffa853201a Mon Sep 17 00:00:00 2001 From: "Jacob A. Morris" Date: Tue, 30 Jun 2026 12:32:01 -0700 Subject: [PATCH] feat: smarter subtask completion with user verification MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - done: only auto-check bullets with an explicitly related passing test; interview user for all others (one question per unchecked bullet) - done: block DONE status if any subtask remains unchecked — task stays IN PROGRESS in Active Work until all bullets are [x] - done: move ### section to ## Completed only when fully complete; never move a section with open [ ] bullets - done: update **Status** line to reflect outcome (āœ… DONE or IN PROGRESS) with today's date in both cases - done: distinguish completion report (āœ… Task Complete) from partial progress report (šŸ”„ Progress Saved) with incomplete subtask list - next: update **Status**: line to IN PROGRESS (date) when starting a task Co-Authored-By: Claude --- skills/done/SKILL.md | 89 +++++++++++++++++++++++++++++++++++++++++--- skills/next/SKILL.md | 6 ++- 2 files changed, 89 insertions(+), 6 deletions(-) diff --git a/skills/done/SKILL.md b/skills/done/SKILL.md index 8e29263..5175340 100644 --- a/skills/done/SKILL.md +++ b/skills/done/SKILL.md @@ -94,14 +94,69 @@ Find the task row and update: ### ~~TASK-XXX~~: Title (āœ… DONE) ``` -#### 4d. Verify All Updated +#### 4d. Verify Subtask Bullets One by One -Search for the task ID and confirm all occurrences show strikethrough or āœ… DONE: +Collect all `- [ ]` bullets within the task's `###` section. For each one, determine how to verify it: + +**If a directly related test exists and tests passed (Step 3):** +A bullet is considered test-covered if the test name, file, or output explicitly references the same feature or behavior described in the bullet. Mark it `[x]` automatically. + +**Otherwise — interview the user for each unchecked bullet:** + +``` +AskUserQuestion({ + questions: [{ + question: "Was this subtask completed? \"[subtask text]\"", + header: "Subtask", + multiSelect: false, + options: [ + { label: "Yes — mark complete", description: "Change [ ] to [x]" }, + { label: "No — leave incomplete", description: "Keep as [ ] for follow-up" } + ] + }] +}) +``` + +- **Yes** → change `- [ ]` to `- [x]` +- **No** → leave as `- [ ]` and record in an **incomplete list** + +**After reviewing all bullets — decide the outcome:** + +- **All bullets are `[x]`** → proceed to mark the task āœ… DONE (steps 4e–4f) +- **Any bullet remains `[ ]`** → the task is NOT done. Skip steps 4a, 4c, 4e, 4f entirely. Instead: + 1. Keep the `###` section header as-is (do not add strikethrough or āœ…) + 2. Update `**Status**:` to `IN PROGRESS (YYYY-MM-DD)` with today's date + 3. Leave the section in `## Active Work` — do NOT move it to `## Completed` + 4. Commit and push the progress (using `wip(TASK-XXX):` prefix), then report incomplete items (Step 6) + +#### 4e. Update the **Status**: Line (fully complete tasks only) + +Find the `**Status**:` line inside the task's `###` section and replace it: + +```markdown +# Before: +**Status**: IN PROGRESS (2026-02-23) + +# After: +**Status**: āœ… DONE (YYYY-MM-DD) +``` + +Use today's date. + +#### 4f. Move Section to ## Completed (fully complete tasks only) + +Cut the entire `###` block (from the `### ~~TASK-XXX~~:` header line down to, but not including, the next `###` or `##` heading) and append it under the `## Completed` section. If no `## Completed` section exists, create one at the end of the file. + +**Never move a section with unchecked `- [ ]` bullets to `## Completed`.** + +#### 4g. Verify All Updated ```bash grep "TASK-XXX" docs/MASTER_PLAN.md ``` +Confirm: if fully complete, all occurrences show strikethrough and āœ… DONE. If incomplete, confirm the section remains in Active Work with IN PROGRESS status. + ### Step 5: Commit and Push Stage all relevant files. **NEVER commit**: @@ -152,17 +207,38 @@ git push ### Step 6: Report Completion -Output this summary: +**If all subtasks were completed:** ``` -## Task Complete +## āœ… Task Complete - **Task**: TASK-XXX (or "Quick fix") - **Summary**: [user's summary] - **Tests**: āœ… Passed (or ā­ļø Skipped) +- **Subtasks**: āœ… All complete - **Commit**: [short hash] — [message] - **Push**: āœ… Pushed to origin -- **MASTER_PLAN.md**: Updated / N/A +- **MASTER_PLAN.md**: Moved to Completed +``` + +**If any subtasks remain incomplete:** + +``` +## šŸ”„ Progress Saved — Task Still In Progress + +- **Task**: TASK-XXX +- **Summary**: [user's summary] +- **Tests**: āœ… Passed / ā­ļø Skipped +- **Subtasks**: āš ļø [N] incomplete (see below) +- **Commit**: [short hash] — wip(TASK-XXX): [message] +- **Push**: āœ… Pushed to origin +- **MASTER_PLAN.md**: Remains IN PROGRESS in Active Work + +### Incomplete Subtasks +- [ ] [subtask text] +- [ ] [subtask text] + +Run `/master-plan:next` to pick this task back up and finish these items. ``` ## Important Rules @@ -173,6 +249,9 @@ Output this summary: 4. **Verify with grep** after updating MASTER_PLAN.md 5. **Wait for user input** — Don't assume or skip questions 6. **Test failures block completion** — If tests fail, stop and report +7. **All subtasks must be `[x]` before marking DONE** — A task with any `[ ]` bullet stays IN PROGRESS +8. **`## Completed` is for fully finished tasks only** — Never move a section there while any subtask is unchecked +9. **Tests only auto-check bullets with an explicitly related test** — All other unchecked bullets require user confirmation ## Files to NEVER Commit diff --git a/skills/next/SKILL.md b/skills/next/SKILL.md index 20695af..812901d 100644 --- a/skills/next/SKILL.md +++ b/skills/next/SKILL.md @@ -132,7 +132,11 @@ AskUserQuestion({ If "Start working on this" is selected: 1. Update the task's status to `IN PROGRESS` in MASTER_PLAN.md (all locations — see update rules below) -2. Confirm: "Started TASK-XXX. Ready to begin implementation." +2. Update the `**Status**:` line inside the task's `###` section to reflect the current date: + ```markdown + **Status**: IN PROGRESS (YYYY-MM-DD) + ``` +3. Confirm: "Started TASK-XXX. Ready to begin implementation." ## MASTER_PLAN.md Update Rules