@studiometa/forge-cli 0.3.0 → 0.4.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.
Files changed (55) hide show
  1. package/README.md +18 -15
  2. package/dist/cli.js +421 -152
  3. package/dist/cli.js.map +1 -1
  4. package/dist/commands/backups/command.d.ts.map +1 -1
  5. package/dist/commands/backups/handlers.d.ts +1 -0
  6. package/dist/commands/backups/handlers.d.ts.map +1 -1
  7. package/dist/commands/backups/help.d.ts.map +1 -1
  8. package/dist/commands/certificates/command.d.ts.map +1 -1
  9. package/dist/commands/certificates/handlers.d.ts +0 -1
  10. package/dist/commands/certificates/handlers.d.ts.map +1 -1
  11. package/dist/commands/certificates/help.d.ts.map +1 -1
  12. package/dist/commands/commands/handlers.d.ts.map +1 -1
  13. package/dist/commands/completion.d.ts.map +1 -1
  14. package/dist/commands/config.d.ts.map +1 -1
  15. package/dist/commands/daemons/command.d.ts.map +1 -1
  16. package/dist/commands/daemons/handlers.d.ts +1 -0
  17. package/dist/commands/daemons/handlers.d.ts.map +1 -1
  18. package/dist/commands/daemons/help.d.ts.map +1 -1
  19. package/dist/commands/database-users/command.d.ts.map +1 -1
  20. package/dist/commands/database-users/handlers.d.ts +1 -0
  21. package/dist/commands/database-users/handlers.d.ts.map +1 -1
  22. package/dist/commands/database-users/help.d.ts.map +1 -1
  23. package/dist/commands/deployments/handlers.d.ts.map +1 -1
  24. package/dist/commands/deployments/help.d.ts.map +1 -1
  25. package/dist/commands/monitors/handlers.d.ts.map +1 -1
  26. package/dist/commands/recipes/command.d.ts.map +1 -1
  27. package/dist/commands/recipes/handlers.d.ts +1 -0
  28. package/dist/commands/recipes/handlers.d.ts.map +1 -1
  29. package/dist/commands/recipes/help.d.ts.map +1 -1
  30. package/dist/commands/redirect-rules/handlers.d.ts.map +1 -1
  31. package/dist/commands/scheduled-jobs/handlers.d.ts.map +1 -1
  32. package/dist/commands/security-rules/command.d.ts.map +1 -1
  33. package/dist/commands/security-rules/handlers.d.ts +1 -0
  34. package/dist/commands/security-rules/handlers.d.ts.map +1 -1
  35. package/dist/commands/security-rules/help.d.ts.map +1 -1
  36. package/dist/commands/sites/command.d.ts.map +1 -1
  37. package/dist/commands/sites/handlers.d.ts +1 -0
  38. package/dist/commands/sites/handlers.d.ts.map +1 -1
  39. package/dist/config.d.ts +1 -1
  40. package/dist/config.d.ts.map +1 -1
  41. package/dist/context.d.ts.map +1 -1
  42. package/dist/{error-handler-Byuujxh1.js → error-handler-ByMitiOr.js} +21 -10
  43. package/dist/error-handler-ByMitiOr.js.map +1 -0
  44. package/dist/error-handler.d.ts.map +1 -1
  45. package/dist/errors.d.ts.map +1 -1
  46. package/dist/index.js +1 -1
  47. package/dist/output.d.ts.map +1 -1
  48. package/dist/types.d.ts +1 -0
  49. package/dist/types.d.ts.map +1 -1
  50. package/dist/utils/args.d.ts +1 -0
  51. package/dist/utils/args.d.ts.map +1 -1
  52. package/dist/utils/command-router.d.ts.map +1 -1
  53. package/dist/utils/resolve.d.ts.map +1 -1
  54. package/package.json +3 -3
  55. package/dist/error-handler-Byuujxh1.js.map +0 -1
package/README.md CHANGED
@@ -18,12 +18,13 @@ npx @studiometa/forge-cli --help
18
18
 
19
19
  Credentials can be provided in three ways (highest priority first):
20
20
 
21
- 1. **CLI argument**: `--token <token>`
22
- 2. **Environment variable**: `FORGE_API_TOKEN`
21
+ 1. **CLI flags**: `--token <token>`, `--org <slug>`
22
+ 2. **Environment variables**: `FORGE_API_TOKEN`, `FORGE_ORG`
23
23
  3. **Config file** (XDG-compliant):
24
24
 
25
25
  ```bash
26
- forge config set YOUR_FORGE_TOKEN
26
+ forge config set apiToken YOUR_FORGE_TOKEN
27
+ forge config set organizationSlug your-org-slug
27
28
  forge config get
28
29
  forge config delete
29
30
  ```
@@ -106,9 +107,10 @@ forge sites list --server 123 --format table
106
107
  ### `config` — Manage configuration
107
108
 
108
109
  ```bash
109
- forge config set <token> # Save API token to config file
110
- forge config get # Show current token (masked)
111
- forge config delete # Delete stored token
110
+ forge config set apiToken <token> # Save API token
111
+ forge config set organizationSlug <slug> # Save organization slug
112
+ forge config get # Show current config (masked)
113
+ forge config delete # Delete all stored config
112
114
  ```
113
115
 
114
116
  ### `servers` (`s`) — Manage servers
@@ -209,15 +211,16 @@ All write operations (`deploy`, `create`, `delete`, `reboot`, `restart`, `update
209
211
 
210
212
  ## Global Options
211
213
 
212
- | Option | Alias | Description |
213
- | ----------------- | ----- | ----------------------------------------------- |
214
- | `--token <token>` | | Forge API token (overrides config and env) |
215
- | `--server <id>` | | Server ID (required for server-scoped commands) |
216
- | `--site <id>` | | Site ID (required for site-scoped commands) |
217
- | `--format <fmt>` | `-f` | Output format: `json`, `human`, `table` |
218
- | `--no-color` | | Disable colored output |
219
- | `--help` | `-h` | Show help |
220
- | `--version` | `-v` | Show version |
214
+ | Option | Alias | Description |
215
+ | ----------------- | ----- | ------------------------------------------------ |
216
+ | `--token <token>` | | Forge API token (overrides config and env) |
217
+ | `--org <slug>` | | Organization slug (overrides config and env) |
218
+ | `--server <id>` | | Server ID or name (auto-resolved if non-numeric) |
219
+ | `--site <id>` | | Site ID or domain (auto-resolved if non-numeric) |
220
+ | `--format <fmt>` | `-f` | Output format: `json`, `human`, `table` |
221
+ | `--no-color` | | Disable colored output |
222
+ | `--help` | `-h` | Show help |
223
+ | `--version` | `-v` | Show version |
221
224
 
222
225
  ## AI Agent Integration
223
226