ci: add npm tarball artifact to release workflow#96
Merged
Conversation
…bols are used Walks the AST after semantic analysis to collect all referenced symbol names (function calls, type references, FB instantiations, inheritance) and matches them against library manifests. Only libraries with at least one referenced symbol (plus transitive dependencies) are injected into the generated C++ output. Test builds (isTestBuild) skip tree-shaking since the test harness may reference any library symbol. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add a new build-npm job that runs `npm pack` to produce a platform-independent .tgz tarball. This artifact is uploaded to GitHub Releases alongside the existing platform-specific binaries. The npm tarball is used by OpenPLC Editor to install STruC++ as a TypeScript dependency (for the compile() API) while also bundling the C++ runtime headers and .stlib libraries in a single versioned artifact. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
build-npmjob to the release workflow that runsnpm packto produce a platform-independent.tgztarball.tgzin GitHub Release assets alongside existing platform-specific binariesContext
OpenPLC Editor is migrating from MatIEC to STruC++ for IEC 61131-3 compilation. The editor needs STruC++ as an npm package (for the
compile()API) and also needs the C++ runtime headers (for Arduino compilation). The.tgzbundles both in a single versioned artifact, following the same download-from-GitHub-Releases pattern used for matiec and xml2st.Test plan
build-npmjob produces a valid.tgzartifactnpm install strucpp-<version>.tgzinstalls correctlydist/,src/runtime/include/, andlibs/🤖 Generated with Claude Code