mirror of
https://github.com/catlog22/Claude-Code-Workflow.git
synced 2026-02-12 02:37:45 +08:00
4.2 KiB
4.2 KiB
name, description, usage, argument-hint, examples, allowed-tools
| name | description | usage | argument-hint | examples | allowed-tools | |||
|---|---|---|---|---|---|---|---|---|
| plan | Project planning and architecture analysis using CLI tools | /cli:mode:plan [--tool <codex|gemini|qwen>] [--enhance] [--cd "path"] "topic" | [--tool codex|gemini|qwen] [--enhance] [--cd path] topic |
|
SlashCommand(*), Bash(*) |
CLI Mode: Plan (/cli:mode:plan)
Purpose
Execute planning and architecture analysis using CLI tools with specialized template.
Supported Tools: codex, gemini (default), qwen
Execution Flow
- Parse tool selection: Extract
--toolflag (default: gemini) - If
--enhanceflag present: Execute/enhance-prompt "[topic]"first - Parse topic (original or enhanced)
- Detect target directory (from
--cdor auto-infer) - Build command for selected tool with planning template
- Execute analysis
- Save to session (if active)
Core Rules
- Enhance First (if flagged): Execute
/enhance-promptbefore planning - Directory Context: Use
cdwhen--cdprovided or auto-detected - Template Required: Always use planning template
- Session Output: Save to
.workflow/WFS-[id]/.chat/plan-[timestamp].md
Command Template
cd [directory] && ~/.claude/scripts/gemini-wrapper --all-files -p "
PURPOSE: [planning goal from topic]
TASK: Comprehensive planning and architecture analysis
CONTEXT: @{CLAUDE.md,**/*CLAUDE.md} [entire codebase in directory]
EXPECTED: Strategic insights, implementation roadmap, key decisions
RULES: $(cat ~/.claude/prompt-templates/plan.md) | Focus on [topic area]
"
File Pattern Reference
Common Patterns
- All files:
@{**/*} - Source files:
@{src/**/*} - TypeScript:
@{*.ts,*.tsx} - JavaScript:
@{*.js,*.jsx} - With docs:
@{CLAUDE.md,**/*CLAUDE.md} - Tests:
@{**/*.test.*,**/*.spec.*} - Config files:
@{*.config.*,**/config/**/*}
Complex Pattern Discovery
For comprehensive planning, use semantic discovery to understand project scope:
# Step 1: Discover project structure
~/.claude/scripts/get_modules_by_depth.sh
mcp__code-index__find_files(pattern="*.ts")
# Step 2: Identify key architectural files
rg "export.*class|export.*interface" --files-with-matches
mcp__code-index__search_code_advanced(pattern="class.*Service|interface.*Config")
# Step 3: Execute planning with full context
cd . && ~/.claude/scripts/gemini-wrapper --all-files -p "
PURPOSE: Plan feature implementation
CONTEXT: @{CLAUDE.md,**/*CLAUDE.md} Full project context
EXPECTED: Architecture design and implementation roadmap
RULES: $(cat ~/.claude/prompt-templates/plan.md) | Focus on scalability
"
Examples
Basic Planning:
cd . && ~/.claude/scripts/gemini-wrapper --all-files -p "
PURPOSE: Design user dashboard feature architecture
TASK: Comprehensive architecture planning for dashboard
CONTEXT: @{CLAUDE.md,**/*CLAUDE.md}
EXPECTED: Architecture design, component structure, implementation roadmap
RULES: $(cat ~/.claude/prompt-templates/plan.md) | Focus on scalability and UX
"
Directory-Specific:
cd src/auth && ~/.claude/scripts/gemini-wrapper --all-files -p "
PURPOSE: Plan authentication system redesign
TASK: Analyze current auth and plan improvements
CONTEXT: @{CLAUDE.md,**/*CLAUDE.md}
EXPECTED: Migration strategy, security improvements, timeline
RULES: $(cat ~/.claude/prompt-templates/plan.md) | Focus on security and backward compatibility
"
With Enhancement:
# User: /gemini:mode:plan --enhance "fix auth issues"
# Step 1: Enhance
/enhance-prompt "fix auth issues"
# Returns structured planning context
# Step 2: Plan with enhanced input
cd . && ~/.claude/scripts/gemini-wrapper --all-files -p "
PURPOSE: [enhanced goal]
TASK: [enhanced task description]
CONTEXT: @{CLAUDE.md,**/*CLAUDE.md} [enhanced context]
EXPECTED: Strategic plan with enhanced requirements
RULES: $(cat ~/.claude/prompt-templates/plan.md) | [enhanced constraints]
"
Session Output
Location: .workflow/WFS-[topic]/.chat/plan-[timestamp].md
Includes:
- Planning topic
- Template used
- Analysis results
- Implementation roadmap
- Key decisions