chore: add release workflow (publish on GitHub Release)#18
Merged
StefanoGuerrini merged 1 commit intomainfrom Apr 21, 2026
Merged
chore: add release workflow (publish on GitHub Release)#18StefanoGuerrini merged 1 commit intomainfrom
StefanoGuerrini merged 1 commit intomainfrom
Conversation
Publishes the package to npm when a GitHub Release is published (or via manual workflow_dispatch). Uses npm publish with provenance so the npmjs listing shows a verified build origin. Guards against version drift: if the release tag (e.g. v2.0.2) does not match package.json version, the job fails before publishing.
4 tasks
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.
Summary
Formalizes npm publishing. Currently publishes are manual (
pnpm publishfrom a maintainer's machine, untagged). This workflow automates it off a GitHub Release.release: published(plusworkflow_dispatchas a manual fallback).package.jsonversion →pnpm check→pnpm test→pnpm build→npm publish --provenance --access public.v2.0.2) doesn't equalpackage.jsonversion, the job fails before publishing.npm publish(notpnpm publish) because npm + provenance is independent of the pnpm version pinned inpackageManager.Prerequisites before the first release
Intended release flow going forward
chore: update version to X.Y.Z— bumpspackage.jsonandexamples/package.json).vX.Y.Zand release notes.Test plan
NPM_TOKENsecret added to repov2.0.2and publishes successfully (separate PR for the version bump)