ci: publish to npm on version tags + release v1.1.0#2
Merged
Conversation
Add a Publish Package workflow that runs on `v*` tags and publishes to npm via OIDC trusted publishing (no token), mirroring FlatIO/embed-client. Bump to 1.1.0 so a v1.1.0 tag publishes the localized-catalogs release.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Sets up automated npm publishing, modeled on
FlatIO/embed-client..github/workflows/publish.yml— runs onv*tag pushes: installs, runsbuild-schema→validate→build→test, thennpm publish --access public. Uses npm OIDC trusted publishing (id-token: write, noNPM_TOKENsecret).package.json— bump1.0.0→1.1.0(the localized-catalogs feature, PR feat: localized instrument catalogs #1), so av1.1.0tag publishes a version that matchespackage.json.How to release after merge
OIDC trusted publishing must be enabled for
@flat/instrumentson npmjs.com before the first run:npmjs.com → package settings → Trusted Publisher → GitHub Actions, pointing at
FlatIO/instruments+ workflowpublish.yml.If the package has never been published (so its npm settings page doesn't exist yet), the very first publish needs a one-off manual
npm publish(or a granularNODE_AUTH_TOKEN); trusted publishing can be configured for every release after that. Let me know which case applies and I'll adjust.