Debugging & maintenanceGitHub source
Fix TODOs
/fix-todosI'll systematically find and resolve TODO comments in your codebase with intelligent understanding and continuity across sessions.
// skill content
Fix TODOs I'll systematically find and resolve TODO comments in your codebase using intelligent analysis and continuity across sessions. Arguments: $ARGUMENTS - files, directories, or specific TODO patterns to fix ## Session Intelligence I'll track progress on resolving TODOs across sessions: Session Files (in the current project directory): - fix-todos/plan.md - All TODOs found and their resolution status - fix-todos/state.json - Current progress and decisions IMPORTANT: Session files are stored in the `fix-todos folder in your current project directory **Auto-Detection:** - If a session exists: Resume from the last TODO - If no session exists: Scan and create a new plan - Commands: resume, status, new ## Phase 1: Discovery & Analysis **MANDATORY FIRST STEPS:** 1. Check if the directory fix-todos exists in the current working directory 2. If the directory exists, check for session files: - Look for fix-todos/state.json - Look for fix-todos/plan.md - If found, resume from the existing session 3. If no directory or session exists: - Scan the entire codebase for TODOs - Create a categorized plan - Initialize progress tracking 4. Display a summary of TODOs before starting I’ll find and categorize all TODOs: **TODO Detection:** - TODO, FIXME, HACK, XXX markers - Different priority levels - Context and complexity assessment - Understanding of related code **Smart Categorization:** - **Quick fixes**: Simple validations, null checks - **Features**: Missing functionality - **Refactoring**: Code improvements - **Security**: Safety and validation needs - **Performance**: Optimization opportunities ## Phase 2: Resolution Planning Based on the analysis, I’ll create a resolution plan: **Priority Order:** 1. Security-critical TODOs 2. Bug-related TODOs 3. Simple improvements 4. Feature additions 5. Performance optimizations I’ll document this plan in a “fix-todos/plan.md” that includes: - The location and details of each TODO - The proposed resolution approach - A risk assessment - The implementation order ## Phase 3: Intelligent Resolution I’ll fix TODOs that match your code patterns: **Pattern Detection:** - Find similar implementations in your code - Match your error-handling style - Use your validation patterns - Follow your naming conventions **Resolution Strategies:** - Error handling → Your try/catch patterns - Validation → Your input-checking style - Performance → Your optimization approach - Security → Your security patterns ## Phase 4: Incremental Implementation I’ll resolve TODOs systematically: **Execution Process:** 1. Create a Git checkpoint 2. Fix the TODO with contextual understanding 3. Verify that functionality is preserved 4. Update the plan to reflect completion 5. Move on to the next TODO **Progress Tracking:** - Mark each TODO as resolved in the plan - Update the state file with decisions - Create meaningful commits ## Phase 5: Verification After each resolution: - Run relevant tests - Check for regressions - Validate integration points - Ensure code quality ## Context Continuity **Session Resume:** When you return and run /fix-todos or /fix-todos resume: - Load existing plan and progress - Show completion statistics - Continue from last TODO - Maintain all resolution decisions **Progress Example:** ` RESUMING TODO FIXES ├── Total TODOs: 47 ├── Resolved: 23 (49%) ├── Current: src/api/auth.js:42 └── Next: src/utils/validation.js:15 Continuing resolution... ` ## Practical Examples **Start Fixing:** ` /fix-todos # Fix all TODOs /fix-todos src/ # Focus on directory /fix-todos "security" # Fix security TODOs ` **Session Control:** ` /fix-todos resume # Continue existing session /fix-todos status # Check progress /fix-todos new # Start fresh ` ## Safety Guarantees **Protection Measures:** - Git checkpoint before changes - Incremental commits - Functionality verification - No TODO removal without implementation **Important:** I will NEVER: - Remove TODOs without fixing them - Break existing functionality - Add AI attribution - Implement without understanding context ## Command Suggestions After resolving critical TODOs: - /test - To ensure fixes work correctly - /commit` - To save TODO resolutions ##
// original public source
notlikeDev/CCPlugins/commands/fix-todos.md
License: MIT License
Independent project, not affiliated with Anthropic. This skill remains the property of its original author.