Skip to content

Conversation

@Mqxx
Copy link
Member

@Mqxx Mqxx commented Jan 21, 2026

  • Refactored the build and publish pipeline
  • Changed JSR package structure
  • Moved the commands needed for publish to their own dedicated sh files

@Mqxx Mqxx marked this pull request as draft January 22, 2026 07:31
@Mqxx Mqxx requested a review from Katze719 January 22, 2026 08:24
@Mqxx Mqxx self-assigned this Jan 22, 2026
@Mqxx Mqxx marked this pull request as ready for review January 22, 2026 08:30
@Mqxx Mqxx marked this pull request as draft January 22, 2026 09:07
@Mqxx Mqxx marked this pull request as ready for review January 22, 2026 09:45
@Mqxx Mqxx requested a review from Katze719 January 26, 2026 12:31
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR refactors how the C++ Linux bindings are built and published to JSR, moving to a reusable artifact-based pipeline and a new JSR package layout. It also adds CI workflows for C++ and Deno integration tests.

Changes:

  • Introduced a new JSR package structure under jsr/ with a TypeScript entrypoint (src/bin/index.ts) and explicit jsr.json manifest.
  • Replaced the previous in-place “embed binary” script with dedicated shell scripts for copying the built .so, converting it to JSON/base64, and stamping the JSR version.
  • Added/updated GitHub Actions workflows to build the shared library once, publish a serialized binary to JSR via a reusable workflow, and run C++ and Deno integration tests.

Reviewed changes

Copilot reviewed 16 out of 19 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
jsr/src/bin/index.ts Adds a TypeScript module that re-exports the serialized x86_64 binary JSON for consumers of @serial/cpp-bindings-linux/bin.
jsr/scripts/set_version.sh Adds a helper script to inject the computed version into jsr/jsr.json before publishing.
jsr/scripts/copy_binary.sh Adds a script to copy the built shared library into the JSR package’s bin/ directory.
jsr/scripts/binary_to_json.sh Adds a script to convert the shared library into a base64-encoded JSON blob with metadata for JSR.
jsr/package/jsr.json.in Removes the old CMake-templated JSR manifest used under the previous jsr/package structure.
jsr/package/README.md Removes the legacy README associated with the old jsr/package layout.
jsr/package/.gitignore Removes legacy ignore rules for the old jsr/package/jsr.json.
jsr/jsr.json Introduces a new, version-stamped JSR manifest at the jsr/ root, exporting ./bin via src/bin/index.ts and defining publish include patterns.
jsr/README.md Adds an updated README for the JSR package, including usage and CI badges.
jsr/LICENSE Adds an LGPLv3 license file scoped to the JSR package.
jsr/.gitignore Ignores generated binary artifacts under jsr/bin/ while allowing tracked sources under jsr/src/bin/.
CMakeLists.txt Updates cmake_git_versioning to v1.1.0 and writes env.sh with PACKAGE_VERSION for use by CI workflows.
.github/workflows/publish_jsr.yml Adds a reusable workflow that prepares artifacts (copy & JSON-encode the binary, set manifest version) and publishes or dry-runs deno publish.
.github/workflows/publish-jsr.yml Removes the old, monolithic “build and publish to JSR” workflow in favor of the new artifact-based pipeline.
.github/workflows/deno_tests.yml Adds a Deno-based integration test workflow that builds the project in a container and runs tests against a virtual serial port.
.github/workflows/cpp_tests.yml Adds a Fedora-based C++ test workflow that builds the project and runs the cpp_bindings_linux_tests suite.
.github/workflows/build_binary.yml Adds a dedicated workflow to build the shared library, capture PACKAGE_VERSION from env.sh, upload the .so artifact, and call the reusable publish_jsr workflow.
.github/workflows/build-deno-so.yml Removes the old workflow that built and uploaded a Deno-targeted .so artifact, superseded by the new build-and-publish pipeline.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@Mqxx Mqxx requested a review from Katze719 January 27, 2026 14:01
@Katze719 Katze719 merged commit 85544a6 into main Jan 28, 2026
5 checks passed
@Katze719 Katze719 deleted the jsr-publish branch January 28, 2026 17:57
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.

3 participants