Skip to content

Add tag-triggered npm release workflow - #4

Merged
michaelmagan merged 1 commit into
mainfrom
add-release-workflow
Aug 22, 2026
Merged

michaelmagan merged 1 commit into
mainfrom
add-release-workflow

Conversation

@michaelmagan

Copy link
Copy Markdown
Contributor

Summary

Adds `release.yml`: pushing a `v*..` tag runs the same `bun run check` gate as CI, verifies the tag matches `package.json`'s version, smoke-tests the real packed tarball (install + run `--version`/`--help`), then publishes to npm via trusted publishing (OIDC) and cuts a GitHub Release.

Follows the same GitHub App / action-pinning conventions as `sync-openapi.yml`.

Before this can run for real

npm trusted publishing has to be configured on npmjs.com for this repo:

  1. Go to https://www.npmjs.com/package/usecharming -> Settings -> Trusted Publisher
  2. Add GitHub Actions publisher: org `tambo-labs`, repo `charming-cli`, workflow `release.yml`

The first publish (`usecharming@0.1.0`) already went out manually with 2FA — OIDC trusted publishing can't perform the first publish of a name that doesn't exist yet on the registry. Every release after that can go through this workflow.

Test plan

  • `bun run check` passes on this branch
  • First real tag push (e.g. `v0.1.1`) after the trusted publisher is configured — not yet exercised, since that config step is a manual npmjs.com action

Publishes to npm via trusted publishing (OIDC) on a v*.*.* tag push,
after running the same check gate as CI and a real pack/install smoke
test of the tarball. Requires the trusted publisher to be configured on
npmjs.com for tambo-labs/charming-cli + this workflow file before the
first run — npm trusted-publisher config lives on the package's own
settings page and can't be set up from the CLI.

First real publish (usecharming@0.1.0) went out manually with 2FA,
since OIDC trusted publishing can't perform the first publish of a
package name that doesn't exist yet. Every release after that can use
this workflow.
@michaelmagan
michaelmagan merged commit 2e3b716 into main Aug 22, 2026
1 check passed
@michaelmagan
michaelmagan deleted the add-release-workflow branch August 22, 2026 20:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant