feat(sea): build single executable application and upload to release#239
Merged
Conversation
Add experimental standalone executables built with Node.js SEA while retaining the npm package as the primary, fully supported distribution. Build each executable on its native GitHub-hosted runner and attach versioned archives to the GitHub release created by Release Please. --- Implementation - Use Node.js 25.9.0 for reproducible SEA builds and keep the normal npm build on the Node version declared by `.nvmrc`. - Build one ESM entry with `vite.sea.config.mts`, disabling code splitting, bundling application dependencies, and leaving `@napi-rs/keyring` external. - Load the native keyring dependency lazily so unsupported OAuth credential storage does not prevent a standalone executable from starting. - Generate executables with `sea-config.json` and `node --build-sea`. - Share setup, build, platform-specific generation, macOS ad-hoc signing, and smoke tests through `.github/actions/build-sea/action.yml`. - Run one Linux x64 SEA smoke build in `.github/workflows/build.yml` to catch packaging regressions before release. - Build release executables on native runners for Linux x64/ARM64, macOS Intel/ARM64, and Windows x64. - Compare the version reported by each executable with the Release Please tag after removing its leading `v`, then verify `--help`. - Archive Unix executables as `.tar.gz` and Windows executables as `.zip` using separate native-shell steps, then upload them with `gh release upload`. - Name release assets `code-ollama-v<version>-<os>-<arch>.<archive>` while keeping the contained executable named `code-ollama` or `code-ollama.exe`. --- Limitations - OAuth authentication for MCP servers is unsupported in standalone executables because the platform-native keyring addon is not embedded. - Document this limitation in the README and direct OAuth users to the npm package. - Keep standalone executables experimental while Node SEA remains under active development.
Codecov Report✅ All modified and coverable lines are covered by tests. 🚀 New features to boost your workflow:
|
…e workflow The action now always: 1. Reads the expected version from `package.json`. 2. Extracts the version from the executable output. 3. Requires an exact match. 4. Verifies `--help`.
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.
What is the motivation for this pull request?
This is a feature that adds experimental standalone executables built with Node.js SEA (Single Executable Applications) while retaining the npm package as the primary, fully supported distribution.
plan.md
What is the current behavior?
The application is only distributed as an npm package that requires Node.js to be installed separately.
What is the new behavior?
code-ollama-v<version>-<os>-<arch>.<archive>Implementation Details
vite.sea.config.mts, disabling code splittingsea-config.jsonandnode --build-sea--helpsmoke testsLimitations
Checklist: