1.5 KiB
1.5 KiB
| description | argument-hint | allowed-tools |
|---|---|---|
| Trace a feature end-to-end across the codebase - find all files, flows, DB tables, quality issues, and dead code | <feature name or description> | Task, Read, Write, Edit, Glob, Grep, Bash |
Trace this feature: $ARGUMENTS
Instructions
Load the feature-tracer skill, then:
1. Discover Entry Points
# API handlers (Go)
grep -rn "[keyword]" --include="*.go" services/*/internal/
# Frontend
grep -rn "[keyword]" --include="*.tsx" --include="*.ts" apps/
# Workers
grep -rn "[keyword]" --include="*.go" workers/*/internal/
2. Trace Each Path
For each entry point:
- Read the file
- Follow each call (service → repository → external)
- Map DB tables touched
- Note external dependencies
3. Assess Quality
For each traced file:
- Has tests? (
ls [file]_test.goorls [file].test.ts) - TODOs? (
grep -n "TODO\|FIXME" [file]) - Dead code? (grep for function callers)
- Error handling adequate?
4. Step Back
- Traced both read AND write paths?
- Checked error/failure paths?
- Verified dead code claims with grep counts?
5. Output
- Entry Points Table - UI, API, Worker with file:line
- Execution Flow - Visual path diagram
- Database Schema - Tables touched
- Quality Assessment - Good / Bad / Ugly / Dead Code
- Uncertainties - What couldn't be traced
Critical Rules
- NEVER mark code as "dead" without grep evidence showing 0 callers
- ALWAYS include file:line references
- ALWAYS note what you couldn't trace