@duvoai/cli 0.3.0 → 0.3.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.
- package/README.md +0 -28
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -128,31 +128,3 @@ duvo --profile team-2 whoami # one-off override for a single command
|
|
|
128
128
|
| `duvo api <method> <path>` | Make a raw authenticated API request |
|
|
129
129
|
|
|
130
130
|
Run `duvo <command> --help` for full flags on any command.
|
|
131
|
-
|
|
132
|
-
## Publishing
|
|
133
|
-
|
|
134
|
-
The CLI is published to npm as [`@duvoai/cli`](https://www.npmjs.com/package/@duvoai/cli) via the [`Publish @duvoai/cli`](../.github/workflows/publish-duvo-cli.yml) GitHub Actions workflow.
|
|
135
|
-
|
|
136
|
-
### How to publish a new version
|
|
137
|
-
|
|
138
|
-
1. Bump `version` in `duvo-cli/package.json` (follow SemVer) and merge to the default branch.
|
|
139
|
-
2. Open the **Actions** tab → **Publish @duvoai/cli** → **Run workflow** and dispatch it from the default branch.
|
|
140
|
-
3. The workflow reads the version from `package.json`, skips if that version is already on npm, otherwise builds the CLI with prod Auth0 config baked in and publishes to npm.
|
|
141
|
-
|
|
142
|
-
### How the workflow works
|
|
143
|
-
|
|
144
|
-
- **Trigger:** manual `workflow_dispatch` only. There is no automatic publish on push or tag.
|
|
145
|
-
- **Auth:** OIDC trusted publishing to npm — no `NPM_TOKEN` is stored in the repo. The npm registry has a Trusted Publisher configured for `@duvoai/cli` pointing at this repo + workflow file. See [npm Trusted Publishers](https://docs.npmjs.com/trusted-publishers).
|
|
146
|
-
- **Idempotent:** `npm view @duvoai/cli@<version>` runs first; if the version already exists the build/publish steps are skipped, so re-running the workflow on an unchanged version is a no-op.
|
|
147
|
-
- **Concurrency:** the job uses `concurrency.group: publish-duvo-cli-${{ github.ref }}` with `cancel-in-progress: false`, so two near-simultaneous dispatches serialize instead of racing past the version check.
|
|
148
|
-
- **Auth0 config baked at build time:** the publish step sets `DUVO_CLI_DOMAIN=login.duvo.ai`, `DUVO_CLI_AUDIENCE=https://api.duvo.ai`, and `DUVO_CLI_CLIENT_ID=${{ secrets.DUVO_CLI_PROD_CLIENT_ID }}` so the published artifact targets the prod Auth0 tenant regardless of who runs `duvo login` and where.
|
|
149
|
-
|
|
150
|
-
### Required secrets
|
|
151
|
-
|
|
152
|
-
| Secret | Purpose |
|
|
153
|
-
| ------------------------- | ----------------------------------------------------------------- |
|
|
154
|
-
| `DUVO_CLI_PROD_CLIENT_ID` | Auth0 prod-tenant Client ID for the "Duvo CLI" Native application |
|
|
155
|
-
|
|
156
|
-
### Yanking a bad release
|
|
157
|
-
|
|
158
|
-
`npm publish` is append-only. To pull a broken version use `npm deprecate @duvoai/cli@<version> "<reason>"` (or in extreme cases, `npm unpublish` within the 72-hour window). Then bump the version in `package.json` and re-run the workflow.
|