# Pair Programming Commands Reference Complete reference for all pair programming session commands. ## Session Control Commands ### /start Start a new pair programming session. ``` /start [--mode ] [--agent ] ``` ### /end End the current session. ``` /end [--save] [--report] ``` ### /pause Pause the current session. ``` /pause [--reason ] ``` ### /resume Resume a paused session. ``` /resume ``` ### /status Show current session status. ``` /status [--verbose] ``` ### /switch Switch driver/navigator roles. ``` /switch [--immediate] ``` ## Code Commands ### /explain Explain the current code or selection. ``` /explain [--level basic|detailed|expert] ``` ### /suggest Get improvement suggestions. ``` /suggest [--type refactor|optimize|security|style] ``` ### /implement Request implementation (navigator mode). ``` /implement ``` ### /refactor Refactor selected code. ``` /refactor [--pattern ] [--scope function|file|module] ``` ### /optimize Optimize code for performance. ``` /optimize [--target speed|memory|both] ``` ### /document Add documentation to code. ``` /document [--format jsdoc|markdown|inline] ``` ### /comment Add inline comments. ``` /comment [--verbose] ``` ### /pattern Apply a design pattern. ``` /pattern [--example] ``` ## Testing Commands ### /test Run test suite. ``` /test [--watch] [--coverage] [--only ] ``` ### /test-gen Generate tests for current code. ``` /test-gen [--type unit|integration|e2e] ``` ### /coverage Check test coverage. ``` /coverage [--report html|json|terminal] ``` ### /mock Generate mock data or functions. ``` /mock [--realistic] ``` ### /test-watch Enable test watching. ``` /test-watch [--on-save] ``` ### /snapshot Create test snapshots. ``` /snapshot [--update] ``` ## Review Commands ### /review Perform code review. ``` /review [--scope current|file|changes] [--strict] ``` ### /security Security analysis. ``` /security [--deep] [--fix] ``` ### /perf Performance analysis. ``` /perf [--profile] [--suggestions] ``` ### /quality Check code quality metrics. ``` /quality [--detailed] ``` ### /lint Run linters. ``` /lint [--fix] [--config ] ``` ### /complexity Analyze code complexity. ``` /complexity [--threshold ] ``` ## Navigation Commands ### /goto Navigate to file or location. ``` /goto [:line[:column]] ``` ### /find Search in project. ``` /find [--regex] [--case-sensitive] ``` ### /recent Show recent files. ``` /recent [--limit ] ``` ### /bookmark Manage bookmarks. ``` /bookmark [add|list|goto|remove] [] ``` ### /history Show command history. ``` /history [--limit ] [--filter ] ``` ### /tree Show project structure. ``` /tree [--depth ] [--filter ] ``` ## Git Commands ### /diff Show git diff. ``` /diff [--staged] [--file ] ``` ### /commit Commit with verification. ``` /commit [--message ] [--amend] ``` ### /branch Branch operations. ``` /branch [create|switch|delete|list] [] ``` ### /stash Stash operations. ``` /stash [save|pop|list|apply] [] ``` ### /log View git log. ``` /log [--oneline] [--limit ] ``` ### /blame Show git blame. ``` /blame [] ``` ## AI Partner Commands ### /agent Manage AI agent. ``` /agent [switch|info|config] [] ``` ### /teach Teach the AI your preferences. ``` /teach ``` ### /feedback Provide feedback to AI. ``` /feedback [positive|negative] ``` ### /personality Adjust AI personality. ``` /personality [professional|friendly|concise|verbose] ``` ### /expertise Set AI expertise focus. ``` /expertise [add|remove|list] [] ``` ## Metrics Commands ### /metrics Show session metrics. ``` /metrics [--period today|session|week|all] ``` ### /score Show quality scores. ``` /score [--breakdown] ``` ### /productivity Show productivity metrics. ``` /productivity [--chart] ``` ### /leaderboard Show improvement leaderboard. ``` /leaderboard [--personal|team] ``` ## Configuration Commands ### /config Manage configuration. ``` /config [get|set|reset] [] [] ``` ### /profile Manage profiles. ``` /profile [use|create|list|delete] [] ``` ### /theme Change interface theme. ``` /theme [dark|light|auto|] ``` ### /shortcuts Manage keyboard shortcuts. ``` /shortcuts [list|set|reset] [] [] ``` ## Collaboration Commands ### /share Share session or code. ``` /share [session|code|screen] [--with ] ``` ### /invite Invite collaborator. ``` /invite [--role observer|participant] ``` ### /chat Send message to team. ``` /chat ``` ### /note Add session note. ``` /note [--tag ] ``` ## Learning Commands ### /learn Access learning resources. ``` /learn [] [--level beginner|intermediate|advanced] ``` ### /example Show code examples. ``` /example [--language ] ``` ### /quiz Take a quiz on current topic. ``` /quiz [--difficulty easy|medium|hard] ``` ### /tip Get a coding tip. ``` /tip [--topic ] ``` ## Utility Commands ### /help Show help. ``` /help [] ``` ### /undo Undo last action. ``` /undo [--steps ] ``` ### /redo Redo undone action. ``` /redo [--steps ] ``` ### /clear Clear screen or cache. ``` /clear [screen|cache|history] ``` ### /export Export session data. ``` /export [--format json|md|html] [--file ] ``` ### /import Import configuration or data. ``` /import [--type config|session|profile] ``` ## Debugging Commands ### /debug Enter debug mode. ``` /debug [on|off|toggle] ``` ### /breakpoint Manage breakpoints. ``` /breakpoint [add|remove|list|clear] [] ``` ### /trace Enable tracing. ``` /trace [on|off|show] ``` ### /inspect Inspect variable or object. ``` /inspect [--deep] ``` ### /watch Watch expression. ``` /watch [add|remove|list] [] ``` ## Advanced Commands ### /macro Record or run macros. ``` /macro [record|stop|play|list|delete] [] ``` ### /plugin Manage plugins. ``` /plugin [install|remove|list|config] [] ``` ### /api API operations. ``` /api [--method GET|POST|PUT|DELETE] [--data ] ``` ### /exec Execute system command. ``` /exec [--background] ``` ## Quick Command Aliases | Alias | Full Command | |-------|-------------| | `/s` | `/suggest` | | `/e` | `/explain` | | `/t` | `/test` | | `/r` | `/review` | | `/c` | `/commit` | | `/g` | `/goto` | | `/f` | `/find` | | `/h` | `/help` | | `/sw` | `/switch` | | `/st` | `/status` | ## Command Modifiers ### Global Modifiers - `--quiet` - Suppress output - `--verbose` - Detailed output - `--json` - JSON output format - `--no-cache` - Skip cache - `--timeout ` - Command timeout ### Chaining Commands Use `&&` to chain commands: ``` /test && /commit && /push ``` ### Command History - `↑/↓` - Navigate history - `Ctrl+R` - Search history - `!!` - Repeat last command - `!` - Run command n from history ## Custom Commands Define custom commands in configuration: ```json { "customCommands": { "tdd": "/test-gen && /test --watch", "full-review": "/lint --fix && /test && /review --strict", "quick-fix": "/suggest --type fix && /implement && /test" } } ``` Use custom commands: ``` /custom tdd /custom full-review ``` ## Best Practices 1. **Learn Core Commands** - Master frequently used commands 2. **Use Aliases** - Speed up common operations 3. **Chain Commands** - Automate workflows 4. **Custom Commands** - Create your workflows 5. **Keyboard Shortcuts** - Faster than typing ## Related Documentation - [Session Management](./session.md) - [Configuration](./config.md) - [Keyboard Shortcuts](./shortcuts.md) - [Getting Started](./README.md)