Files
Claude-Code-Workflow/.claude/commands/workflow/session/resume.md
catlog22 754f9b8da0 修复所有命令文件的usage格式:斜杠改为冒号
统一命令调用格式从 /workflow/session/list 改为 /workflow:session:list

## 修复范围
- workflow/session/: 6个子命令 (start, pause, resume, list, status, switch)
- workflow/issue/: 4个子命令 (create, list, update, close)
- workflow/: 3个主命令 (plan, execute, review)
- task/: 4个命令 (create, execute, breakdown, replan)
- gemini/: 3个命令 (chat, execute, analyze)

## 格式统一
- usage行: /workflow:session:list
- examples: /workflow:session:start "任务"
- 标题: # Command (/workflow:session:start)
- 内容引用: 所有命令路径统一使用冒号格式

## 验证完成
 24个命令文件全部采用统一格式
 所有examples和内容引用保持一致
 parent字段同步更新

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-09-08 16:32:41 +08:00

82 lines
2.0 KiB
Markdown

---
name: workflow-session-resume
description: Resume the most recently paused workflow session
usage: /workflow:session:resume
parent: /workflow:session
---
# Resume Workflow Session (/workflow:session:resume)
## Purpose
Resume the most recently paused workflow session, restoring all context and state.
## Usage
```bash
/workflow:session:resume
```
## Resume Logic
### Session Detection
- Finds most recently paused session
- Loads session state from `workflow-session.json`
- Validates session integrity
### State Restoration
- Creates `.workflow/.active-[session-name]` marker file
- Loads current phase from session state
- Restores appropriate agent context
- Continues from exact interruption point
### Context Continuity
- Restores TodoWrite state
- Loads phase-specific context
- Maintains full audit trail
- Preserves document references
## Phase-Specific Resume
### Planning Phase
- Resumes planning document generation
- Maintains requirement analysis progress
- Continues task breakdown where left off
### Implementation Phase
- Resumes task execution state
- Maintains agent coordination
- Continues from current task
### Review Phase
- Resumes validation process
- Maintains quality checks
- Continues review workflow
## Session Validation
Before resuming, validates:
- Session directory exists
- Required documents present
- State consistency
- No corruption detected
## Output
Displays:
- Resumed session ID and description
- Current phase and progress
- Available next actions
- Session directory location
## Error Handling
- **No paused sessions**: Lists available sessions to switch to
- **Corrupted session**: Attempts recovery or suggests manual repair
- **Directory missing**: Clear error with recovery options
- **State inconsistency**: Validates and repairs where possible
## Next Actions
After resuming:
- Use `/context` to view current session state
- Continue with phase-appropriate commands
- Check TodoWrite status for next steps
---
**Result**: Previously paused session is now active and ready to continue