Principle:A5c ai Babysitter Package Publication
| Knowledge Sources | |
|---|---|
| Domains | Release_Pipeline, Package_Publication |
| Last Updated | 2026-10-23 00:00 GMT |
Overview
A practice of publishing npm packages under candidate dist-tags from release tags, ensuring no premature mutation of production channels.
Description
Package Publication is the principle of publishing each package to npm under a candidate dist-tag (never latest, staging, or develop). The candidate tag is a non-production marker that allows validation before promotion. The publication reads the release version from the release plan, builds the package, and runs npm publish --tag <candidate> --access public --ignore-scripts.
The --ignore-scripts flag prevents lifecycle scripts from executing during publication, ensuring deterministic, side-effect-free publishing.
Usage
Use this principle when publishing packages in a CI pipeline where promotion to production channels must be a separate, gated step.
Theoretical Basis
The publication flow is a single package-at-a-time operation:
for each package in releaseMatrix:
version = reconcileReleaseVersion(releasePlan, package)
build(package) unless skipBuild
npm publish --tag <candidate-tag> --access public --ignore-scripts
Key property: The candidate dist-tag is never one of the production channels. Channel mutation happens ONLY in the promotion step, creating a single gate between candidate and production.