Repository navigation
feat: build and publish preset binaries - #82
Draft
spiral-ladder wants to merge 1 commit into
Draft
spiral-ladder wants to merge 1 commit into
spiral-ladder wants to merge 1 commit into
Conversation
Add an optional zapi.presets list to package.json. Each preset is a build of the same step with extra zig build args. The 1st preset is the mainnet preset (the default) and keeps <binaryName>.node. The 2nd preset is the minimal preset <binaryName>-minimal.node `requireNapiLibrary(dir, preset)` selects one at load time. `zapi build --preset <name>` renames a local build to match. A preset is bundled into the target packages unless it is marked standalone, in which case prepublish and publish emit it as its own <name>-<preset>-<target> packages that are left out of the main package's `optionalDependencies`, so consumers download it only when they depend on it explicitly. Motivation: lodestar-z compiles the consensus preset in, and lodestar's minimal-preset spec tests need a minimal binary that production installs should not have to download.
Member
Author
|
putting this in draft first bc a lot of the text is still quite slop/verbose, i want to trim it down |
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.
Add an optional zapi.presets list to package.json. Each preset is a build of the same step with extra zig build args.
The 1st preset is the mainnet preset (the default) and keeps .node. The 2nd preset is the minimal preset -minimal.node
requireNapiLibrary(dir, preset)selects one at load time.zapi build --preset <name>renames a local build to match.A preset is bundled into the target packages unless it is marked standalone, in which case prepublish and publish emit it as its own -- packages that are left out of the main package's
optionalDependencies, so consumers download it only when they depend on it explicitly.Motivation: lodestar-z compiles the consensus preset in, and lodestar's minimal-preset spec tests need a minimal binary that production installs should not have to download.