@raster-app/cli 0.3.1 → 0.3.2
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 +2 -2
- package/dist/index.js +3 -3
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -32,7 +32,7 @@ For CI and scripts, use an organization API key instead (create one in Raster un
|
|
|
32
32
|
raster auth login --api-key pk_…
|
|
33
33
|
```
|
|
34
34
|
|
|
35
|
-
Or set `RASTER_API_KEY`. The bearer credential resolves from the `--api-key` flag, then a stored OAuth token, then
|
|
35
|
+
Or set `RASTER_API_KEY`. The bearer credential resolves from the `--api-key` flag, then `RASTER_API_KEY`, then a stored OAuth token, then a stored config API key. `raster auth status` shows which credential is active. `raster auth logout` revokes an OAuth token and removes stored credentials.
|
|
36
36
|
|
|
37
37
|
## Org and library are derived from the key
|
|
38
38
|
|
|
@@ -135,7 +135,7 @@ Human-readable tables print to stdout; progress and notes go to stderr, so stdou
|
|
|
135
135
|
|
|
136
136
|
| Variable | Purpose |
|
|
137
137
|
| --- | --- |
|
|
138
|
-
| `RASTER_API_KEY` | API key (
|
|
138
|
+
| `RASTER_API_KEY` | API key (overrides a stored OAuth token; sits below `--api-key`, above a config-file key) |
|
|
139
139
|
| `RASTER_ORG` | Default organization id for an OAuth login when `--org` is omitted |
|
|
140
140
|
| `RASTER_CONFIG_HOME` | Config directory override (default `~/.config/raster`) |
|
|
141
141
|
| `RASTER_AUTH_ISSUER` | OAuth authorization-server issuer (default `https://raster.app`; a `raster.app` host or localhost only) |
|
package/dist/index.js
CHANGED
|
@@ -16337,7 +16337,7 @@ config(en_default());
|
|
|
16337
16337
|
// package.json
|
|
16338
16338
|
var package_default = {
|
|
16339
16339
|
name: "@raster-app/cli",
|
|
16340
|
-
version: "0.3.
|
|
16340
|
+
version: "0.3.2",
|
|
16341
16341
|
description: "Command-line client for the Raster API",
|
|
16342
16342
|
license: "Apache-2.0",
|
|
16343
16343
|
type: "module",
|
|
@@ -17410,10 +17410,10 @@ async function ensureFreshOAuthSession(options) {
|
|
|
17410
17410
|
function resolveCredential(options) {
|
|
17411
17411
|
if (options.flagKey)
|
|
17412
17412
|
return { kind: "apiKey", key: options.flagKey, source: "flag" };
|
|
17413
|
-
if (options.config.oauth)
|
|
17414
|
-
return { kind: "oauth", tokens: options.config.oauth };
|
|
17415
17413
|
if (options.env.RASTER_API_KEY)
|
|
17416
17414
|
return { kind: "apiKey", key: options.env.RASTER_API_KEY, source: "env" };
|
|
17415
|
+
if (options.config.oauth)
|
|
17416
|
+
return { kind: "oauth", tokens: options.config.oauth };
|
|
17417
17417
|
if (options.config.apiKey)
|
|
17418
17418
|
return { kind: "apiKey", key: options.config.apiKey, source: "config" };
|
|
17419
17419
|
return null;
|