filex-cli 0.1.0 → 0.1.1

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.
Files changed (43) hide show
  1. package/README.md +33 -25
  2. package/dist/filex.cjs +91 -0
  3. package/package.json +8 -6
  4. package/dist/bin/filex.d.ts +0 -3
  5. package/dist/bin/filex.d.ts.map +0 -1
  6. package/dist/bin/filex.js +0 -5
  7. package/dist/bin/filex.js.map +0 -1
  8. package/dist/src/actions/convertImages.d.ts +0 -16
  9. package/dist/src/actions/convertImages.d.ts.map +0 -1
  10. package/dist/src/actions/convertImages.js +0 -101
  11. package/dist/src/actions/convertImages.js.map +0 -1
  12. package/dist/src/actions/mergePdfs.d.ts +0 -12
  13. package/dist/src/actions/mergePdfs.d.ts.map +0 -1
  14. package/dist/src/actions/mergePdfs.js +0 -132
  15. package/dist/src/actions/mergePdfs.js.map +0 -1
  16. package/dist/src/actions/resizeImages.d.ts +0 -11
  17. package/dist/src/actions/resizeImages.d.ts.map +0 -1
  18. package/dist/src/actions/resizeImages.js +0 -71
  19. package/dist/src/actions/resizeImages.js.map +0 -1
  20. package/dist/src/ai/explain.d.ts +0 -15
  21. package/dist/src/ai/explain.d.ts.map +0 -1
  22. package/dist/src/ai/explain.js +0 -75
  23. package/dist/src/ai/explain.js.map +0 -1
  24. package/dist/src/ai/parseIntent.d.ts +0 -18
  25. package/dist/src/ai/parseIntent.d.ts.map +0 -1
  26. package/dist/src/ai/parseIntent.js +0 -145
  27. package/dist/src/ai/parseIntent.js.map +0 -1
  28. package/dist/src/cli.d.ts +0 -2
  29. package/dist/src/cli.d.ts.map +0 -1
  30. package/dist/src/cli.js +0 -149
  31. package/dist/src/cli.js.map +0 -1
  32. package/dist/src/confirm.d.ts +0 -17
  33. package/dist/src/confirm.d.ts.map +0 -1
  34. package/dist/src/confirm.js +0 -69
  35. package/dist/src/confirm.js.map +0 -1
  36. package/dist/src/scan.d.ts +0 -27
  37. package/dist/src/scan.d.ts.map +0 -1
  38. package/dist/src/scan.js +0 -79
  39. package/dist/src/scan.js.map +0 -1
  40. package/dist/src/schema.d.ts +0 -224
  41. package/dist/src/schema.d.ts.map +0 -1
  42. package/dist/src/schema.js +0 -52
  43. package/dist/src/schema.js.map +0 -1
package/README.md CHANGED
@@ -1,11 +1,11 @@
1
1
  # FileX
2
2
 
3
- A terminal CLI for safe local file operations with optional AI assistance.
3
+ A CLI agent to modify and interact with your files.
4
4
 
5
5
  ## Installation
6
6
 
7
7
  ```bash
8
- npm install -g filex
8
+ npm install -g filex-cli
9
9
  ```
10
10
 
11
11
  ## Usage
@@ -15,57 +15,65 @@ npm install -g filex
15
15
  ```bash
16
16
  # Convert images to WebP
17
17
  filex convert ./photos
18
- filex convert ./photos --max-width 1600 --quality 90
18
+ filex convert ./photos --from png --to webp --quality 90
19
+
20
+ # Convert with resizing
21
+ filex convert ./photos --to jpg --max-width 1600
19
22
 
20
23
  # Resize images
21
24
  filex resize ./photos --max-width 800
22
25
 
23
26
  # Merge PDFs
24
27
  filex merge-pdfs ./documents
25
- filex merge-pdfs ./documents --output combined.pdf
28
+ filex merge-pdfs ./documents --output combined.pdf --order date
26
29
  ```
27
30
 
28
- ### AI-Driven Usage
31
+ ### AI-Powered Mode
29
32
 
30
- Set your Gemini API key:
31
- ```bash
32
- export GEMINI_API_KEY="your-api-key"
33
- ```
33
+ Use natural language to describe what you want:
34
34
 
35
- Then use natural language:
36
35
  ```bash
37
- filex "convert all images here to webp and make them smaller for web"
36
+ filex "convert all images here to webp"
38
37
  filex "resize these photos to 1200px wide" --directory ./photos
39
- filex "merge all the PDFs in this folder"
38
+ filex "merge all the PDFs by date, newest first"
39
+ filex "convert png files to jpg at 90% quality"
40
40
  ```
41
41
 
42
42
  ## Commands
43
43
 
44
44
  | Command | Description |
45
45
  |---------|-------------|
46
- | `convert <dir>` | Convert PNG/JPG/JPEG to WebP |
47
- | `resize <dir>` | Resize images to max width |
48
- | `merge-pdfs <dir>` | Merge all PDFs alphabetically |
46
+ | `convert <dir>` | Convert images between formats |
47
+ | `resize <dir>` | Resize images to a max width |
48
+ | `merge-pdfs <dir>` | Merge all PDFs in a directory |
49
49
 
50
50
  ## Options
51
51
 
52
52
  ### convert
53
- - `--max-width <px>` - Maximum width in pixels
54
- - `--quality <1-100>` - Output quality (default: 80)
53
+ | Option | Description | Default |
54
+ |--------|-------------|---------|
55
+ | `--from <format>` | Source format (png, jpg, webp, gif, tiff, avif) | all |
56
+ | `--to <format>` | Target format (webp, png, jpg) | webp |
57
+ | `--max-width <px>` | Maximum width in pixels | — |
58
+ | `--quality <1-100>` | Output quality | 80 |
55
59
 
56
60
  ### resize
57
- - `--max-width <px>` - Maximum width in pixels (required)
61
+ | Option | Description |
62
+ |--------|-------------|
63
+ | `--max-width <px>` | Maximum width in pixels *(required)* |
58
64
 
59
65
  ### merge-pdfs
60
- - `-o, --output <file>` - Output filename (default: merged.pdf)
66
+ | Option | Description | Default |
67
+ |--------|-------------|---------|
68
+ | `-o, --output <file>` | Output filename | merged.pdf |
69
+ | `--order <type>` | Sort: name, name-desc, date, date-desc, random | name |
61
70
 
62
- ## Safety Guarantees
71
+ ## Safety
63
72
 
64
- - ✅ **Originals are never deleted** - All operations create new files
65
- - ✅ **Confirmation before writes** - Preview planned actions and approve
66
- - ✅ **AI is sandboxed** - AI only parses intent, never touches files
67
- - ✅ **Graceful errors** - Clear messages, no crashes on edge cases
68
- - ✅ **Works without AI** - Manual commands function independently
73
+ - ✅ **Originals preserved** All operations create new files
74
+ - ✅ **Preview before write** Confirm planned actions first
75
+ - ✅ **AI sandboxed** AI only parses intent, never touches files directly
76
+ - ✅ **Works offline** Manual commands function without AI
69
77
 
70
78
  ## License
71
79