File contents Technical Debt Cleanup
Finds and cleans up technical debt in the codebase before ending a session.
Inspection Items
1. Duplicate Code
Check if similar functions/logic exist across multiple files
Identify code that could be extracted into common utilities
2. Unused Code
Unused import statements
Unused variables/functions
Commented-out code blocks
3. Debug Code
console.log / console.error
debugger statements
Temporary comments (// TODO, // FIXME, // HACK, // XXX)
4. Code Quality
any type usage (TypeScript)
Hardcoded values (magic numbers/strings)
Functions that are too long (over 50 lines)
Deep nesting (over 4 levels)
Inspection Commands
# Find console.log
grep -r "console\." --include="*.ts" --include="*.tsx" src/
# Find TODO comments
grep -rn "TODO\|FIXME\|HACK\|XXX" --include="*.ts" --include="*.tsx" src/
# Find any types
grep -rn ": any" --include="*.ts" --include="*.tsx" src/
Output Format
## Technical Debt Report
### Duplicate Code (3 items)
- src/utils.ts:formatDate <-> src/helpers.ts:formatDateTime
### Unused Imports (12 items)
- src/components/Button.tsx: React (unused)
### Debug Code (5 items)
- src/api/auth.ts:23 - console.log
### Code Quality Issues (8 items)
- src/services/user.ts:45 - any type usage
Total 28 technical debt items found.
Proceed with automatic fixes? (Y/n)
Auto-Fix Scope
Remove unused imports
Remove console.log/debugger
Duplicate code: report only (manual review needed)
1 --- 2 name: techdebt-2 3 description: Technical Debt Cleanup 4 --- 5 6 # Technical Debt Cleanup 7 8 Finds and cleans up technical debt in the codebase before ending a session. 9 10 ## Inspection Items 11 12 ### 1. Duplicate Code 13 - Check if similar functions/logic exist across multiple files 14 - Identify code that could be extracted into common utilities 15 16 ### 2. Unused Code 17 - Unused import statements 18 - Unused variables/functions 19 - Commented-out code blocks 20 21 ### 3. Debug Code 22 - console.log / console.error 23 - debugger statements 24 - Temporary comments (// TODO, // FIXME, // HACK, // XXX) 25 26 ### 4. Code Quality 27 - any type usage (TypeScript) 28 - Hardcoded values (magic numbers/strings) 29 - Functions that are too long (over 50 lines) 30 - Deep nesting (over 4 levels) 31 32 ## Inspection Commands 33 ```bash 34 # Find console.log 35 grep -r "console\." --include="*.ts" --include="*.tsx" src/ 36 37 # Find TODO comments 38 grep -rn "TODO\|FIXME\|HACK\|XXX" --include="*.ts" --include="*.tsx" src/ 39 40 # Find any types 41 grep -rn ": any" --include="*.ts" --include="*.tsx" src/ 42 ``` 43 44 ## Output Format 45 ``` 46 ## Technical Debt Report 47 48 ### Duplicate Code (3 items) 49 - src/utils.ts:formatDate <-> src/helpers.ts:formatDateTime 50 51 ### Unused Imports (12 items) 52 - src/components/Button.tsx: React (unused) 53 54 ### Debug Code (5 items) 55 - src/api/auth.ts:23 - console.log 56 57 ### Code Quality Issues (8 items) 58 - src/services/user.ts:45 - any type usage 59 60 Total 28 technical debt items found. 61 Proceed with automatic fixes? (Y/n) 62 ``` 63 64 ## Auto-Fix Scope 65 - Remove unused imports 66 - Remove console.log/debugger 67 - Duplicate code: report only (manual review needed)
jh941213/my-cc-harness/tree/main/skills_en/techdebt commit 077222d75e
Frequently asked questions How do I install the Techdebt skill? Run npx skillmds@latest add jh941213/techdebt-2 in your terminal (requires Node.js), paste this page's agent-chat prompt into Claude, Cursor, or any MCP-connected agent, or download the SKILL.md file and copy it into your agent's skills directory.
What does the Techdebt skill do? Technical Debt Cleanup It is listed under Coding & Dev Tools on SkillMD.
Is Techdebt safe to use? This skill has not completed SkillMD's automated safety review yet. SkillMD never runs a skill's scripts for you; review the SKILL.md before installing.
Which AI agents work with Techdebt? This skill is tagged as working with Claude Code, Claude.ai, OpenAI Codex. SKILL.md is an open format, so most agents that read a skills directory can load it too.
Is Techdebt free to use? Yes. Installing skills from SkillMD is free, and the skill stays under its author's original license.
Who published Techdebt? jh941213 (@jh941213) published this skill. Their other Agent Skills are listed on their SkillMD profile.