This repository has separate release flows for TypeScript and Rust.
- Use the documented Node runtime (
nvm use) before TypeScript release checks. - Use Rust 1.93.0 or newer before Rust release checks.
- The local preflight script allows uncommitted package metadata changes so it can run during release preparation. Commit release changes before publishing.
- Confirm public package metadata points at the final repository URL before publishing:
- npm:
repository,homepage, andbugsintypescript/packages/wellformed/package.json - crates.io:
repositoryin each Rust crate manifest
- npm:
- Confirm
README.md, package README files, and docs links point at the public docs and issue tracker. - Enable GitHub private vulnerability reporting or add a monitored security contact to
SECURITY.md. - Prefer npm Trusted Publishing with provenance for public npm releases. Configure the package's npm Trusted Publisher to the final public GitHub repository and release workflow before relying on OIDC-based publishing.
Before publishing, confirm the public repository and docs endpoints resolve. For the currently staged metadata, this should succeed:
bash scripts/release-preflight.sh --externalSet WELLFORMED_REPO or WELLFORMED_DOCS_URL to test a different public
repository or docs domain. If you use a monitored security contact instead of
GitHub private vulnerability reporting, add it to SECURITY.md and run with
WELLFORMED_SECURITY_CONTACT_CONFIRMED=1.
If the public repository or docs domain changes, update package manifests,
SECURITY.md, GitHub issue template contact links, package READMEs, and
AI-agent docs before publishing.
TypeScript packages are managed from typescript/.
- Add a changeset for user-facing changes:
cd typescript
pnpm changeset- Create release versions and changelogs:
pnpm run version- Build and verify:
bash scripts/release-preflight.sh --typescript- Publish (when approved):
pnpm run releaseFor automated npm releases, prefer npm Trusted Publishing over long-lived npm
tokens. The authorized GitHub Actions workflow needs id-token: write; npm
generates provenance for public packages published from trusted public
repositories. For manual releases, use an npm account with 2FA and verify the
published tarball metadata after publishing.
Rust crates are currently released manually.
- Update versions in:
wellformed/Cargo.tomlwellformed-macros/Cargo.tomlwellformed-validate/Cargo.toml- workspace references as needed
-
Update
CHANGELOG.md. -
Verify:
bash scripts/release-preflight.sh --rustIf the release changes address parsing predicates or the address feature,
verify it on a machine with native libpostal installed:
bash scripts/release-preflight.sh --addressThose environment variables are required for libpostal installs whose headers
are visible through pkg-config but not through Clang's default include path,
such as Homebrew on Apple Silicon.
- Dry-run and publish in dependency order.
wellformedwill not package from a clean crates.io index untilwellformed-validateis published, andwellformed-macroswill not package untilwellformedis published.
cargo publish --dry-run -p wellformed-validate
cargo publish -p wellformed-validate
cargo publish --dry-run -p wellformed
cargo publish -p wellformed
cargo publish --dry-run -p wellformed-macros
cargo publish -p wellformed-macrosIf you want automation later, release-plz is the cleanest option for workspace crates and can generate release PRs + changelog updates.