ci(release): publish @tomic/* packages to npm on a v* tag - #1355
Open
joepio wants to merge 2 commits into
Open
Conversation
Tag releases published crates.io and GitHub assets but left npm as a manual `pnpm publish -r`. That is why latest is still 0.40.0 and the beta tag is stuck on 0.41.0-beta.0. Pre-releases use the beta/rc dist-tag so they cannot replace latest. Co-authored-by: joepmeindertsma <joepmeindertsma@gmail.com>
A single filter list compiles cli in parallel with lib, which fails TS2307 on a fresh checkout. lib's prepublishOnly attw also crashes (undefined filename), so publish uses --ignore-scripts after the explicit build. Co-authored-by: joepmeindertsma <joepmeindertsma@gmail.com>
joepio
marked this pull request as ready for review
September 3, 2026 19:37
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.
Related Issues
Tag releases published crates.io and GitHub assets but never npm.
@tomic/liblatestis still 0.40.0 andbetais stuck on 0.41.0-beta.0 (2025-06-23); v0.41.0-beta.1 through beta.4 never reached the registry.What changed
npmjob inrelease.yml, independent of the crates job so a 401 from npmjs.org cannot re-attempt a crates.io publish that already succeeded.pnpm publish -r --no-git-checks --ignore-scripts --access public --tag <dist-tag>— skipsprivatepackages and any version already on the registry, so a partial run can be retried.@tomic/libfirst, then the dependents. A single--filterlist compiles them concurrently andtscfails with TS2307 on a fresh checkout.--ignore-scriptsbecause@tomic/lib'sprepublishOnly→attwcurrently crashes (Cannot read properties of undefined (reading 'filename')), which would fail every release. Theworkspace:*rewrite is done bypnpm publishitself.v0.41.0-beta.4→beta,v0.41.0→latest) so a beta cannot replace the stable install. Logic is inscripts/npm-dist-tag.mjs(--checkcovered).@tomic/pluginand@tomic/edit-modegetpublishConfig.access: public(neither has ever been published).pnpm publish -rpath is the fallback.Auth (needs a one-time setup)
The job reads
secrets.NPM_TOKEN(granular automation token, write to@tomic) and also hasid-token: writefor npm Trusted Publishing. Configure one of:NPM_TOKEN, or@tomic/*package at npmjs.com: repoontola/atomic-server, workflowrelease.yml.Without either, the job will 401 — which is louder than silently not publishing.
Verified locally
node scripts/npm-dist-tag.mjs --check— 8 casesnode scripts/bump-version.mjs --check 0.41.0-beta.4— 15 sites agreepnpm publish -r --dry-run --no-git-checks --ignore-scripts --access public --tag betapacks and would publish all seven@tomic/*packages; private workspace members are skipped; packed@tomic/reactand@tomic/clirewriteworkspace:*to0.41.0-beta.4Checklist