Skip to content

ci: add release workflow for crates.io and npm distribution#18

Merged
developer0hye merged 1 commit into
mainfrom
ci/release-publish
Mar 10, 2026
Merged

ci: add release workflow for crates.io and npm distribution#18
developer0hye merged 1 commit into
mainfrom
ci/release-publish

Conversation

@developer0hye

Copy link
Copy Markdown
Owner

Summary

  • Add cross-platform release CI triggered by v* tag push
  • Publish Rust crates to crates.io (marknest-coremarknestmarknest-server)
  • Distribute CLI binary via npm platform-specific packages (npx marknest)
  • Build matrix: macOS arm64/x64, Linux x64/arm64, Windows x64
  • Create GitHub Releases with binary assets

Key changes

  • Cargo.toml: Publish metadata (description, repository, keywords, categories) for all crates
  • LICENSE: MIT license file
  • npm/: Umbrella package with JS shim + 5 platform-specific binary packages
  • .github/workflows/release.yml: Full release pipeline (build → crates.io → npm → GitHub Release)
  • scripts/version-bump.sh: Syncs version across all Cargo.toml and npm package.json files
  • README.md: Installation section (cargo, npm/npx, from source)

How to release

./scripts/version-bump.sh 0.1.0
git commit -am 'chore: bump version to 0.1.0'
git tag v0.1.0
git push && git push --tags

Required GitHub secrets

  • CARGO_REGISTRY_TOKEN: crates.io API token
  • NPM_TOKEN: npm automation access token

Test plan

  • cargo check passes with updated Cargo.toml
  • All 114 tests pass
  • cargo publish --dry-run succeeds for marknest-core
  • Verify release workflow after merging (push a tag)
  • Verify crate names available on crates.io
  • Verify marknest name available on npm

🤖 Generated with Claude Code

Set up cross-platform release CI triggered by version tags (v*).
Builds native binaries for 5 targets (macOS arm64/x64, Linux x64/arm64,
Windows x64), publishes Rust crates to crates.io in dependency order,
and distributes CLI binaries via platform-specific npm packages.

- Add publish metadata (description, repository, keywords) to all crates
- Add LICENSE (MIT)
- Create npm wrapper package with platform-specific optionalDependencies
- Create GitHub Actions release workflow with matrix build
- Add version-bump script for synchronized version updates
- Update README with installation instructions

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Signed-off-by: Yonghye Kwon <developer.0hye@gmail.com>
@developer0hye developer0hye merged commit 4c7b6a5 into main Mar 10, 2026
2 checks passed
@developer0hye developer0hye deleted the ci/release-publish branch March 10, 2026 15:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant