mirror of
https://github.com/catlog22/Claude-Code-Workflow.git
synced 2026-02-13 02:41:50 +08:00
refactor: eliminate TodoWrite duplication in skill-memory phases
Simplify TodoWrite updates in each phase to one-line format, matching auto-parallel.md pattern.
**Changes**:
- Phase 1-4: Replace code block with single line "Mark phase X completed, phase Y in_progress"
- Maintain detailed TodoWrite Pattern section for complete reference
- Remove 32 redundant lines (36 deletions, 4 insertions)
**Before**:
```
**TodoWrite Update**:
```javascript
TodoWrite({todos: [
{"content": "...", "status": "completed"},
{"content": "...", "status": "in_progress"},
...
]})
```
**After**:
```
**TodoWrite**: Mark phase X completed, phase Y in_progress
```
**Benefits**:
- Eliminates duplication between phase updates and TodoWrite Pattern section
- Improves readability with concise phase-level updates
- Maintains complete TodoWrite lifecycle in dedicated pattern section
- Consistent with auto-parallel.md orchestrator pattern
**File size**: 488 lines → 456 lines (-32 lines, -6.6%)
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -112,15 +112,7 @@ bash(test -d .workflow/docs/my_project && echo "still_exists" || echo "deleted")
|
||||
- Existing docs count retrieved (or 0 after regenerate)
|
||||
- Default values set for unspecified parameters
|
||||
|
||||
**TodoWrite Update**:
|
||||
```javascript
|
||||
TodoWrite({todos: [
|
||||
{"content": "Parse arguments and prepare", "status": "completed", "activeForm": "Parsing arguments"},
|
||||
{"content": "Call /memory:docs to plan documentation", "status": "in_progress", "activeForm": "Calling /memory:docs"},
|
||||
{"content": "Execute documentation generation", "status": "pending", "activeForm": "Executing documentation"},
|
||||
{"content": "Generate SKILL.md index", "status": "pending", "activeForm": "Generating SKILL.md"}
|
||||
]})
|
||||
```
|
||||
**TodoWrite**: Mark phase 1 completed, phase 2 in_progress
|
||||
|
||||
**After Phase 1**: Display preparation results → **Automatically continue to Phase 2** (no user input required)
|
||||
|
||||
@@ -160,15 +152,7 @@ SlashCommand(command="/memory:docs [targetPath] --tool [tool] --mode [mode] [--c
|
||||
- Task files created in `.workflow/[docsSessionId]/.task/`
|
||||
- workflow-session.json exists in session directory
|
||||
|
||||
**TodoWrite Update**:
|
||||
```javascript
|
||||
TodoWrite({todos: [
|
||||
{"content": "Parse arguments and prepare", "status": "completed", "activeForm": "Parsing arguments"},
|
||||
{"content": "Call /memory:docs to plan documentation", "status": "completed", "activeForm": "Calling /memory:docs"},
|
||||
{"content": "Execute documentation generation", "status": "in_progress", "activeForm": "Executing documentation"},
|
||||
{"content": "Generate SKILL.md index", "status": "pending", "activeForm": "Generating SKILL.md"}
|
||||
]})
|
||||
```
|
||||
**TodoWrite**: Mark phase 2 completed, phase 3 in_progress
|
||||
|
||||
**After Phase 2**: Display docs planning results (session ID, task count) → **Automatically continue to Phase 3** (no user input required)
|
||||
|
||||
@@ -192,15 +176,7 @@ SlashCommand(command="/workflow:execute")
|
||||
- At minimum, module documentation files exist (API.md and/or README.md)
|
||||
- For full mode: Project README, ARCHITECTURE, EXAMPLES files generated
|
||||
|
||||
**TodoWrite Update**:
|
||||
```javascript
|
||||
TodoWrite({todos: [
|
||||
{"content": "Parse arguments and prepare", "status": "completed", "activeForm": "Parsing arguments"},
|
||||
{"content": "Call /memory:docs to plan documentation", "status": "completed", "activeForm": "Calling /memory:docs"},
|
||||
{"content": "Execute documentation generation", "status": "completed", "activeForm": "Executing documentation"},
|
||||
{"content": "Generate SKILL.md index", "status": "in_progress", "activeForm": "Generating SKILL.md"}
|
||||
]})
|
||||
```
|
||||
**TodoWrite**: Mark phase 3 completed, phase 4 in_progress
|
||||
|
||||
**After Phase 3**: Display execution results (file count, module count) → **Automatically continue to Phase 4** (no user input required)
|
||||
|
||||
@@ -258,15 +234,7 @@ Everything + [Examples](../../.workflow/docs/{project_name}/EXAMPLES.md)
|
||||
- Module index includes all documented modules
|
||||
- All file references use relative paths
|
||||
|
||||
**TodoWrite Update**:
|
||||
```javascript
|
||||
TodoWrite({todos: [
|
||||
{"content": "Parse arguments and prepare", "status": "completed", "activeForm": "Parsing arguments"},
|
||||
{"content": "Call /memory:docs to plan documentation", "status": "completed", "activeForm": "Calling /memory:docs"},
|
||||
{"content": "Execute documentation generation", "status": "completed", "activeForm": "Executing documentation"},
|
||||
{"content": "Generate SKILL.md index", "status": "completed", "activeForm": "Generating SKILL.md"}
|
||||
]})
|
||||
```
|
||||
**TodoWrite**: Mark phase 4 completed
|
||||
|
||||
**After Phase 4**: Workflow complete → **Report final summary to user**
|
||||
|
||||
|
||||
Reference in New Issue
Block a user