This document describes the minimal steps to publish a new version of
@sparse-supernova/spike-qubo-solver to npm.
It assumes:
- You have publish rights for the package scope.
- You have
npmconfigured with the correct account. - You are on the default branch (e.g.
main) and your local tree is clean.
Edit package.json and bump the version using semantic versioning:
- Patch: bugfixes, internal changes only
- Minor: new features, backwards-compatible
- Major: breaking API changes
Example:
"version": "0.1.0"
→
"version": "0.1.1"Install dependencies:
npm installRun tests:
npm testRun benchmarks (optional but recommended):
npm run bench
npm run bench:compareIf any of these fail, fix them before publishing.
Currently this package is pure ESM JavaScript and does not require a build step.
If a build step is added in the future, document it here (e.g. npm run build),
and ensure the compiled artifacts are included in the published package.
You can see what would be published without actually pushing to npm:
npm publish --dry-runCheck:
- Included files
- Entry points (
main,exports) - License and README
When you are satisfied:
npm publish --access publicIf using a scoped package (e.g. @sparse-supernova/spike-qubo-solver),
--access public may be required on the first publish.
Create a git tag that matches the version:
VERSION=$(node -p "require('./package.json').version")
git tag "v$VERSION"
git push origin "v$VERSION"This makes it easy to correlate npm versions with source code.
After publishing:
- Check GitHub Actions (CI workflow) is green on the tag.
- Optionally add the changelog entry in a
CHANGELOG.md(if you introduce one).
- This package is intended as a public optimisation sandbox.
- Keep the published surface minimal and generic.
- Do not add private or proprietary modules to the published package.