@tsuga/cli 1.0.18 → 1.1.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 (3) hide show
  1. package/README.md +38 -7
  2. package/dist/cli.js +59 -64
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -12,18 +12,49 @@ npm install -g @tsuga/cli
12
12
  tsuga --help
13
13
  ```
14
14
 
15
+ ## Updating
16
+
17
+ Update to the latest published version:
18
+
19
+ ```bash
20
+ tsuga self-update
21
+ ```
22
+
23
+ This runs `npm install -g @tsuga/cli@latest`. The CLI also checks for new versions once a day and prints a notice when one is available.
24
+
15
25
  ## Authentication
16
26
 
17
- Before authenticating, generate an Operation API key from your [Tsuga account settings](https://app.tsuga.com/settings/api-keys?operation=true).
27
+ All authentication lives under `tsuga auth`.
28
+
29
+ ### Log in as a user (recommended)
30
+
31
+ For interactive use, log in as a user with a browser authorization flow:
32
+
33
+ ```bash
34
+ # Prints an authorization URL. On macOS, also opens it in your browser.
35
+ tsuga auth login
36
+
37
+ # Print the saved user access token
38
+ tsuga auth token
39
+
40
+ # Show the current authentication method
41
+ tsuga auth status
42
+
43
+ # Clear the saved user session
44
+ tsuga auth logout
45
+ ```
46
+
47
+ After `tsuga auth login`, commands work without an Operation API key.
48
+
49
+ ### Operation API key
18
50
 
19
- The recommended way to authenticate is to save your Operation API key once:
51
+ For non-interactive use (CI, scripts), authenticate with an Operation API key. Generate one from your [Tsuga account settings](https://app.tsuga.com/settings/api-keys?operation=true), then save it once:
20
52
 
21
53
  ```bash
22
- tsuga auth <operation-api-key>
54
+ tsuga auth operation-key <operation-api-key>
23
55
  ```
24
56
 
25
- This writes your operation-api-key to `~/.config/tsuga/config.json`.
26
- Alternatively, set credentials per-session without saving:
57
+ This writes your operation-api-key to `~/.config/tsuga/config.json`. Alternatively, set it per-session without saving:
27
58
 
28
59
  ```bash
29
60
  # Environment variable
@@ -33,7 +64,7 @@ export TSUGA_OPERATION_API_KEY=<operation-api-key>
33
64
  tsuga --operation-api-key <operation-api-key> dashboards list
34
65
  ```
35
66
 
36
- Priority order: `--operation-api-key` flag → `TSUGA_OPERATION_API_KEY` env var → saved config.
67
+ A `--operation-api-key` flag or `TSUGA_OPERATION_API_KEY` env var overrides the saved credential for that one invocation.
37
68
 
38
69
  ## Configuration
39
70
 
@@ -328,7 +359,7 @@ tsuga install plugin claude-code
328
359
  tsuga install plugin codex
329
360
  ```
330
361
 
331
- Adds the `tsuga` marketplace (`tsuga-dev/agent-plugins`) and installs the `tsuga` plugin via the target CLI (`claude` / `codex` must be on `PATH`). Pass `--include-telemetry` to also install the `telemetry` plugin. For Claude Code, marketplace auto-update is enabled by patching `~/.claude/settings.json` with `extraKnownMarketplaces.tsuga.autoUpdate = true`; pass `--no-auto-update` to skip. Restart any running `claude` / `codex` sessions afterward.
362
+ Adds the `tsuga` marketplace (`tsuga-dev/agent-plugins`) and installs the `tsuga` plugin via the target CLI (`claude` / `codex` must be on `PATH`). For Claude Code, marketplace auto-update is enabled by patching `~/.claude/settings.json` with `extraKnownMarketplaces.tsuga.autoUpdate = true`; pass `--no-auto-update` to skip. Restart any running `claude` / `codex` sessions afterward.
332
363
 
333
364
  ## Documentation
334
365