Skip to content

v0.1.3

Choose a tag to compare

@github-actions github-actions released this 31 Jan 20:54
· 9 commits to main since this release
f6e71dd

docprims v0.1.3

Release Date: 2026-01-31
Status: Patch Release (TypeScript CI/CD)

Summary

This release adds CI/CD automation for TypeScript bindings, enabling cross-platform prebuilds and npm trusted publishing.

Highlights

  • Cross-platform prebuilds workflow: Builds native addons for all supported platforms via GitHub Actions
  • npm trusted publishing: OIDC-based workflow for secure, automated npm releases
  • Platform packages: Optional dependencies for seamless npm install without local Rust toolchain

CI/CD Workflows

TypeScript N-API Prebuilds (typescript-napi-prebuilds.yml)

Builds .node native addons for all supported platforms:

Platform Runner Method
linux-x64-gnu ubuntu-latest zig cross-compile (glibc 2.17 baseline)
linux-x64-musl ubuntu-latest zig cross-compile
linux-arm64-gnu ubuntu-latest-arm64-s native build
linux-arm64-musl ubuntu-latest zig cross-compile
darwin-arm64 macos-14 native build
win32-x64-msvc windows-latest native build

Outputs:

  • Per-platform artifacts with .node files
  • Combined ts-npm-dir artifact with platform package structure

TypeScript npm Publish (typescript-npm-publish.yml)

Publishes to npm using OIDC trusted publishing:

  1. Validates workflow runs from a release tag
  2. Verifies VERSION file and package.json match the tag
  3. Downloads prebuilds from a matching workflow run
  4. Publishes platform packages first, then root package

Features:

  • Dry-run mode for validation
  • Explicit prebuilds run ID input (or auto-selects latest for commit)
  • Post-publish verification

Package Structure

The TypeScript package now uses optional dependencies for platform binaries:

{
  "optionalDependencies": {
    "@3leaps/docprims-linux-x64-gnu": "0.1.3",
    "@3leaps/docprims-linux-x64-musl": "0.1.3",
    "@3leaps/docprims-linux-arm64-gnu": "0.1.3",
    "@3leaps/docprims-linux-arm64-musl": "0.1.3",
    "@3leaps/docprims-darwin-arm64": "0.1.3",
    "@3leaps/docprims-win32-x64-msvc": "0.1.3"
  }
}

The native loader (src/native.ts) now:

  1. First checks for local build (git checkout / local path installs)
  2. Falls back to platform package (npm optional dependency)

Installation

From npm (after publish)

npm install @3leaps/docprims

Platform-specific binaries install automatically.

From git checkout

cd bindings/typescript/docprims
npm install
npm run build:native

Unsupported Platforms

The following platforms are not supported:

  • darwin-x64 (Intel Mac) - no demand, easily added if needed
  • win32-arm64 - no Go bindings support either

Changelog

See CHANGELOG.md for detailed changes.