understand-codebase
Installation
SKILL.md
Understand Codebase
Use when navigating code, tracing how functions/classes connect, finding where symbols are defined or called, or answering "how does this work" questions about a codebase.
Tool Selection
| Need | Tool |
|---|---|
| Structural patterns (functions, classes, syntax, call flows) | sg (ast-grep) |
| Text patterns (strings, comments, names) | rg (ripgrep) |
| File discovery by name/extension | fd |
Choose ripgrep (rg) for:
- Text-based searches (strings, comments, variable names)
- Fast, simple pattern matching across many files
- When exact code structure doesn't matter
- Regex searches with context lines
- Searching binary files or non-code text