oh-my-node-modules 1.0.0 → 1.2.5
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 +34 -43
- package/dist/cli.js +3347 -1592
- package/dist/index.js +531 -825
- package/package.json +12 -11
- package/dist/cli.d.ts +0 -3
- package/dist/cli.d.ts.map +0 -1
- package/dist/index.d.ts +0 -562
- package/dist/index.d.ts.map +0 -1
package/README.md
CHANGED
|
@@ -1,38 +1,20 @@
|
|
|
1
1
|
# oh-my-node-modules
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Find and clean up node_modules directories to free disk space.
|
|
4
4
|
|
|
5
|
-
##
|
|
5
|
+
## Install
|
|
6
6
|
|
|
7
7
|
```bash
|
|
8
|
-
#
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
# Or use with npx
|
|
12
|
-
npx oh-my-node-modules
|
|
13
|
-
|
|
14
|
-
# Start interactive TUI
|
|
15
|
-
onm
|
|
16
|
-
|
|
17
|
-
# Quick scan report
|
|
18
|
-
onm --scan
|
|
8
|
+
# With Bun
|
|
9
|
+
bun install -g oh-my-node-modules
|
|
19
10
|
|
|
20
|
-
#
|
|
21
|
-
|
|
11
|
+
# With npm
|
|
12
|
+
npm install -g oh-my-node-modules
|
|
22
13
|
```
|
|
23
14
|
|
|
24
|
-
## Features
|
|
25
|
-
|
|
26
|
-
- **Interactive TUI**: Full terminal UI with keyboard navigation
|
|
27
|
-
- **Size Visualization**: Color-coded sizes (red >1GB, yellow >500MB)
|
|
28
|
-
- **Smart Selection**: Multi-select, select all, invert, select by size
|
|
29
|
-
- **Safe Deletion**: Confirmation prompts, dry-run mode, in-use detection
|
|
30
|
-
- **Filtering**: Search and filter projects by name or path
|
|
31
|
-
- **Progress Tracking**: Visual feedback during scan and delete operations
|
|
32
|
-
|
|
33
15
|
## Usage
|
|
34
16
|
|
|
35
|
-
### Interactive
|
|
17
|
+
### Interactive mode
|
|
36
18
|
|
|
37
19
|
```bash
|
|
38
20
|
onm # Start in current directory
|
|
@@ -44,45 +26,54 @@ Keyboard shortcuts:
|
|
|
44
26
|
- `Space` - Toggle selection
|
|
45
27
|
- `d` - Delete selected
|
|
46
28
|
- `a` - Select all
|
|
29
|
+
- `n` - Deselect all
|
|
30
|
+
- `i` - Invert selection
|
|
47
31
|
- `s` - Change sort
|
|
48
32
|
- `f` - Filter
|
|
49
33
|
- `q` - Quit
|
|
50
34
|
- `?` - Help
|
|
51
35
|
|
|
52
|
-
### CLI
|
|
36
|
+
### CLI mode
|
|
53
37
|
|
|
54
38
|
```bash
|
|
55
|
-
# Quick scan
|
|
39
|
+
# Quick scan report
|
|
56
40
|
onm --scan
|
|
57
41
|
|
|
58
42
|
# JSON output
|
|
59
43
|
onm --scan --json
|
|
60
44
|
|
|
61
|
-
# Auto-delete
|
|
45
|
+
# Auto-delete large node_modules
|
|
62
46
|
onm --auto --min-size 500mb --yes
|
|
63
|
-
onm --auto --dry-run # Preview only
|
|
64
|
-
```
|
|
65
47
|
|
|
66
|
-
|
|
48
|
+
# Preview what would be deleted
|
|
49
|
+
onm --auto --min-size 1gb --dry-run
|
|
50
|
+
```
|
|
67
51
|
|
|
68
|
-
|
|
69
|
-
# Install dependencies
|
|
70
|
-
npm install
|
|
52
|
+
## Features
|
|
71
53
|
|
|
72
|
-
|
|
73
|
-
|
|
54
|
+
- Interactive terminal UI
|
|
55
|
+
- Color-coded sizes (red >1GB, yellow >500MB)
|
|
56
|
+
- Multi-select with keyboard shortcuts
|
|
57
|
+
- Safe deletion with dry-run mode
|
|
58
|
+
- Filter by project name or path
|
|
59
|
+
- Shows last modified date
|
|
74
60
|
|
|
75
|
-
|
|
76
|
-
npm test
|
|
61
|
+
## Development
|
|
77
62
|
|
|
78
|
-
|
|
79
|
-
npm run typecheck
|
|
63
|
+
Requires [Bun](https://bun.sh/).
|
|
80
64
|
|
|
81
|
-
|
|
82
|
-
|
|
65
|
+
```bash
|
|
66
|
+
bun install
|
|
67
|
+
bun run build
|
|
68
|
+
bun test
|
|
69
|
+
bun run dev # Watch mode
|
|
83
70
|
```
|
|
84
71
|
|
|
85
|
-
|
|
72
|
+
The built output works with both Bun and Node.js.
|
|
73
|
+
|
|
74
|
+
## Architecture
|
|
75
|
+
|
|
76
|
+
See [AGENTS.md](./AGENTS.md) for codebase documentation.
|
|
86
77
|
|
|
87
78
|
## License
|
|
88
79
|
|