Scan codebase for Outfitter Stack adoption candidates. Identifies throw statements, console usage, hardcoded paths, and custom errors. Use when assessing adoption scope or checking readiness.
View on GitHubplugins/outfitter-stack/skills/stack-audit/SKILL.md
February 1, 2026
Select agents to install to:
npx add-skill https://github.com/outfitter-dev/agents/blob/main/plugins/outfitter-stack/skills/stack-audit/SKILL.md -a claude-code --skill stack-auditInstallation paths:
.claude/skills/stack-audit/# Stack Audit
Scan a codebase to identify Outfitter Stack adoption candidates and generate an audit report.
## Quick Start
**Option 1: Run the scanner** (recommended for large projects)
```bash
bun run plugins/outfitter-stack/skills/stack-audit/scripts/init-audit.ts [project-root]
```
Generates `.outfitter/adopt/` with:
- `audit-report.md` - Scan results and scope
- `plan/` - Stage-by-stage task files
**Option 2: Manual scan** (smaller projects)
Run the audit commands below to understand scope.
## Audit Commands
### Critical Issues - Exceptions
```bash
# Count throw statements
rg "throw (new |[a-zA-Z])" --type ts -c
# List throw locations
rg "throw (new |[a-zA-Z])" --type ts -n
# Count try-catch blocks
rg "(try \{|catch \()" --type ts -c
```
### Console Usage
```bash
# Count console statements
rg "console\.(log|error|warn|debug|info)" --type ts -c
# List console locations
rg "console\.(log|error|warn|debug|info)" --type ts -n
```
### Hardcoded Paths
```bash
# Homedir usage
rg "(homedir\(\)|os\.homedir)" --type ts -c
# Tilde paths
rg "~/\." --type ts -c
# Combined path issues
rg "(homedir|~\/\.)" --type ts -n
```
### Custom Error Classes
```bash
# Find custom error classes
rg "class \w+Error extends Error" --type ts -n
# Count usage of custom errors
rg "new MyCustomError\(" --type ts -c
```
## Generated Structure
```
.outfitter/adopt/
├── audit-report.md # Scan results, scope, recommendations
└── plan/
├── 00-overview.md # Status dashboard, dependencies
├── 01-foundation.md # Dependencies, context, logger
├── 02-handlers.md # Handler conversions
├── 03-errors.md # Error taxonomy mappings
├── 04-paths.md # XDG path migrations
├── 05-adapters.md # CLI/MCP transport layers
├── 06-documents.md # Documentation updates
└── 99-unknowns.md # Items requiring review
```
## Migration Stages
| Stage | Blocked By | Focus |
|-------|------------|-------|
|