Publishing and packaging
Publishing and packaging
FlowDelta is published to npm as @syntax-syllogism/flow-delta.
The npm version lifecycle synchronizes the GitHub Actions example’s caret pin with the package major and minor version. The release tool stages the updated example with the manifest and lockfile.
Build
npm run build runs scripts/build.mjs, which bundles the six CLI and reporter entrypoints:
dist/cli.jsdist/gitlab-report.jsdist/github-report.jsdist/flexipage-cli.jsdist/flexipage-gitlab-report.jsdist/flexipage-github-report.js
Each file gets a Node shebang and is marked executable. Runtime dependencies stay external, so the published package loads xml2js and elkjs from npm instead of bundling them.
What’s in the package
The manifest publishes:
dist/NOTICELICENSELICENSE-APACHEREADME.md
The binaries map like this:
| Binary | Target |
|---|---|
flow-delta | dist/cli.js |
flow-delta-gitlab | dist/gitlab-report.js |
flow-delta-github | dist/github-report.js |
flexipage-delta | dist/flexipage-cli.js |
flexipage-delta-gitlab | dist/flexipage-gitlab-report.js |
flexipage-delta-github | dist/flexipage-github-report.js |
Before you release
Run these in order:
npm run typechecknpm run buildnpm testnpm pack --jsonnpm run typecheck also runs in repository CI and in prepublishOnly, ahead of the build and tests. The packed tarball should contain the six dist entrypoints and the license files above.
The release CLI updates the pinned source links in these docs to the new release tag as part of the release commit.
The vendored parser is Apache-2.0, so NOTICE and LICENSE-APACHE must ship with the package. See Vendoring policy for provenance and the do-not-edit rule.