claude-use 3.0.0 → 4.0.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 +8 -5
- package/dist/cli.cjs +1882 -1431
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -57,7 +57,9 @@ Sharing composes through a cascade (shipped defaults, then a user-global overrid
|
|
|
57
57
|
|
|
58
58
|
`claude` refuses to launch while `ANTHROPIC_API_KEY`, `ANTHROPIC_AUTH_TOKEN`, `CLAUDE_CODE_OAUTH_TOKEN` or a `CLAUDE_CODE_USE_BEDROCK`/`VERTEX`/`FOUNDRY` variable is set in the environment, because those outrank every identity's stored credential and would make all identities authenticate as the same account. Opt in deliberately with `CLAUDE_USE_ALLOW_AMBIENT_CREDENTIAL=1` for one launch or `claude-use identity set <name> --allow-ambient-credential`.
|
|
59
59
|
|
|
60
|
-
|
|
60
|
+
Providers and identities take their token from one `credential` block: an ordered list of sources (`env`, `file`, `command`, and the `op` and `keychain` presets, plus a `literal` placeholder for a local proxy), tried in turn, and a target (`bearer`, `apiKey`, or `oauthToken` for an identity). The token reaches the child's environment only; `check`, `doctor` and `--json` report the source kind and target, never the value.
|
|
61
|
+
|
|
62
|
+
The full mechanics, including the credential block, the merge algorithm, conditional sharing rules (age, size, git branch, environment), the ambient-credential launch guard, and how `~/.claude/projects/` history is pattern-matched, are in [docs/configuration-model.md](docs/configuration-model.md). Worked examples are in [docs/examples.md](docs/examples.md).
|
|
61
63
|
|
|
62
64
|
## CLI reference
|
|
63
65
|
|
|
@@ -68,6 +70,7 @@ claude-use identity add <name>
|
|
|
68
70
|
claude-use identity list [--json]
|
|
69
71
|
claude-use identity show <name> [--json]
|
|
70
72
|
claude-use identity set <name> [--default-profile <profile> | --no-default-profile] [--[no-]allow-ambient-credential]
|
|
73
|
+
claude-use identity set <name> [--credential <source>]... [--credential-target <bearer|apiKey|oauthToken>] [--no-credential]
|
|
71
74
|
claude-use identity remove <name> [--yes]
|
|
72
75
|
claude-use identity use <name>
|
|
73
76
|
claude-use @<name> # shorthand for `identity use <name>`
|
|
@@ -83,8 +86,8 @@ claude-use profile show <name> [--json]
|
|
|
83
86
|
claude-use profile remove <name> [--yes]
|
|
84
87
|
claude-use profile use <name> # the global default configuration profile
|
|
85
88
|
|
|
86
|
-
claude-use provider add <name> --display-name <name> --base-url <url> (--
|
|
87
|
-
claude-use provider set <name> [--display-name <name>] [--base-url <url>] [--
|
|
89
|
+
claude-use provider add <name> --display-name <name> --base-url <url> (--credential <source>)... [--credential-target <bearer|apiKey>] [--env KEY=VALUE]...
|
|
90
|
+
claude-use provider set <name> [--display-name <name>] [--base-url <url>] [--credential <source>]... [--credential-target <bearer|apiKey>] [--env KEY=VALUE]... [--unset-env KEY]...
|
|
88
91
|
claude-use provider list [--json]
|
|
89
92
|
claude-use provider show <name> [--json]
|
|
90
93
|
claude-use provider remove <name> [--yes]
|
|
@@ -111,9 +114,9 @@ claude-use run [@<identity>] [launch flags] [claude arguments]
|
|
|
111
114
|
claude @<identity> ... # the same, once `claude-use shim enable` has run
|
|
112
115
|
```
|
|
113
116
|
|
|
114
|
-
Every `list`, `show`, `check`, `doctor` and `headroom status` prints text by default and JSON with `--json`. Prompts appear only when standard input is a terminal; without one, a command that needs input fails with the option that supplies it (a `remove` needs `--yes`). Failures print as `claude-use: <message>` and exit 1, usage errors exit 2, a selected provider
|
|
117
|
+
Every `list`, `show`, `check`, `doctor` and `headroom status` prints text by default and JSON with `--json`. Prompts appear only when standard input is a terminal; without one, a command that needs input fails with the option that supplies it (a `remove` needs `--yes`). Failures print as `claude-use: <message>` and exit 1, usage errors exit 2, a selected provider or identity whose credential block yields no token exits 64, and `CLAUDE_USE_DEBUG=1` adds stack traces to unexpected errors. `claude-use completion <bash|zsh|fish>` prints a shell completion script.
|
|
115
118
|
|
|
116
|
-
`claude-use check [path]` resolves the full cascade for a directory without touching the farm, and is the primary way to answer "why is X shared or hidden here". `claude-use doctor` audits the whole `~/.claude-use` config graph at once: every identity, profile, `extends` chain, and directory rule, plus whether the right `claude-use` is the one actually on `PATH`.
|
|
119
|
+
`claude-use check [path]` resolves the full cascade for a directory without touching the farm, and is the primary way to answer "why is X shared or hidden here". `claude-use doctor` audits the whole `~/.claude-use` config graph at once: every identity, profile, `extends` chain, provider (naming the exact replacement for a file still in the format before the credential block) and directory rule, plus whether the right `claude-use` is the one actually on `PATH`.
|
|
117
120
|
|
|
118
121
|
The full per-setting flag and environment-variable table (global, one-off, and directory-scoped forms of every setting), and the file-precedence rules `configure` uses when writing a toggle, are in [docs/cli-reference.md](docs/cli-reference.md).
|
|
119
122
|
|