roast-my-codebase 1.0.0 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +57 -15
- package/dist/index.js +10194 -2551
- package/package.json +4 -4
package/README.md
CHANGED
|
@@ -114,24 +114,43 @@ npx roast-my-codebase --markdown-file # Save to .roast-report.md
|
|
|
114
114
|
### Fully Supported
|
|
115
115
|
- **JavaScript** (.js, .jsx, .mjs, .cjs)
|
|
116
116
|
- **TypeScript** (.ts, .tsx)
|
|
117
|
-
- **Python** (.py)
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
117
|
+
- **Python** (.py) — Complexity, type hints, imports, docstrings, security, class design
|
|
118
|
+
- **Go** (.go) — Complexity, error handling, lint conventions
|
|
119
|
+
- **Rust** (.rs) — Complexity, unsafe usage, clippy hints
|
|
120
|
+
- **Java** (.java) — Complexity, code smells, naming conventions
|
|
121
|
+
- **C#** (.cs) — Complexity, code smells, async patterns
|
|
122
|
+
|
|
123
|
+
### Framework-Specific Checks
|
|
124
|
+
|
|
125
|
+
| Framework | What's detected |
|
|
126
|
+
|-----------|----------------|
|
|
127
|
+
| **Next.js** | Missing metadata exports, server/client component misuse |
|
|
128
|
+
| **React** | Missing error boundaries |
|
|
129
|
+
| **Vue 3** | Options API in Vue 3, v-for without :key, deep watchers |
|
|
130
|
+
| **Angular** | Missing OnPush strategy, direct DOM manipulation, untyped events |
|
|
131
|
+
| **Svelte** | Reactive side effects, inaccessible buttons |
|
|
132
|
+
| **Express** | Missing error middleware, no rate limiting, sync I/O in routes |
|
|
133
|
+
| **FastAPI** | Missing response_model, sync endpoints, missing status codes |
|
|
134
|
+
|
|
135
|
+
### Language-Specific Checks
|
|
136
|
+
|
|
137
|
+
| Language | Scanners |
|
|
138
|
+
|----------|----------|
|
|
139
|
+
| Python | Cyclomatic complexity, type hints, imports, docstrings, code smells, security, class design |
|
|
140
|
+
| Go | Complexity, ignored errors, panic usage, undocumented exports, init() |
|
|
141
|
+
| Rust | Complexity, unsafe blocks, .unwrap() overuse, .clone() overuse, dead_code |
|
|
142
|
+
| Java | Complexity, God classes, raw types, empty catches, System.out, naming |
|
|
143
|
+
| C# | Complexity, God classes, #regions, async void, sync-over-async, empty catches |
|
|
121
144
|
|
|
122
145
|
### Universal Features (All Languages)
|
|
123
146
|
- File size analysis
|
|
124
147
|
- TODO/FIXME detection
|
|
125
|
-
- Git insights
|
|
126
|
-
- Security scans
|
|
148
|
+
- Git insights (churn, PR size, stale branches)
|
|
149
|
+
- Security scans (secrets, .env in git, eval)
|
|
150
|
+
- Test coverage gaps
|
|
151
|
+
- Framework best practices (Next.js, React)
|
|
127
152
|
|
|
128
|
-
|
|
129
|
-
- Go (.go)
|
|
130
|
-
- Rust (.rs)
|
|
131
|
-
- Java (.java)
|
|
132
|
-
- C# (.cs)
|
|
133
|
-
|
|
134
|
-
Language detection is automatic! The tool detects your project's languages and runs appropriate scanners.
|
|
153
|
+
Language detection is automatic! The tool detects your project's languages via package files and runs appropriate scanners.
|
|
135
154
|
|
|
136
155
|
## Design principles
|
|
137
156
|
|
|
@@ -265,7 +284,12 @@ roast-my-codebase --interactive
|
|
|
265
284
|
- ✅ Remove unused dependencies (`npm uninstall`)
|
|
266
285
|
- ✅ Add issue references to TODO comments
|
|
267
286
|
- ✅ Remove dead exports
|
|
268
|
-
-
|
|
287
|
+
- ✅ Add `'use client'` directive to Next.js components
|
|
288
|
+
- ✅ Add missing metadata export to Next.js pages
|
|
289
|
+
- ✅ Add `.env` files to `.gitignore`
|
|
290
|
+
- ✅ Upgrade `@ts-ignore` to `@ts-expect-error`
|
|
291
|
+
- ✅ Create skeleton test files for untested source files
|
|
292
|
+
- ✅ Add secret files to `.gitignore`
|
|
269
293
|
|
|
270
294
|
**Example session:**
|
|
271
295
|
```
|
|
@@ -289,7 +313,25 @@ Unused dependency `lodash` is installed but never imported
|
|
|
289
313
|
Exit interactive mode
|
|
290
314
|
```
|
|
291
315
|
|
|
292
|
-
###
|
|
316
|
+
### HTML Report
|
|
317
|
+
```bash
|
|
318
|
+
roast-my-codebase --html-file
|
|
319
|
+
```
|
|
320
|
+
- Saves `.roast-report.html` — a beautiful standalone HTML report
|
|
321
|
+
- Dark theme, SVG health gauge, sortable findings table, severity chart
|
|
322
|
+
- Fully self-contained (no CDN, works offline)
|
|
323
|
+
- Perfect for sharing with the team
|
|
324
|
+
|
|
325
|
+
# Incremental Scanning
|
|
326
|
+
```bash
|
|
327
|
+
roast-my-codebase --incremental # Only changed files since last commit
|
|
328
|
+
roast-my-codebase --since main # Only files changed since branching from main
|
|
329
|
+
```
|
|
330
|
+
- Dramatically faster on large repos — only scans changed files
|
|
331
|
+
- Global findings (circular deps, excessive dependencies) are always shown
|
|
332
|
+
- Falls back to full scan if not in a git repository
|
|
333
|
+
|
|
334
|
+
# Watch Mode
|
|
293
335
|
```bash
|
|
294
336
|
roast-my-codebase --watch
|
|
295
337
|
```
|