The key: when a precompiled build may stand in for a local compile. Pure functions over the project's lock, the manifest entry and the toolchain, so every rule is testable without a network or a build.
Summary
Functions
The identity of a build's bytes: sha256 over its files' path, sha256 and mode, in path order. Two manifest entries with the same hash install the same files. nil for an entry with a malformed file list, or a path with a NUL or newline, which could pass one file off as another's line.
Lock-closure children of nerves; nerves_bootstrap recompiles them whenever it compiles nerves.
Types
@type ctx() :: %{ optional(:manager) => String.t() | nil, optional(:overrides) => [atom()], optional(:build_method_unknown) => String.t() | nil, name: String.t(), version: String.t(), lock_entry: tuple(), lock: map(), system: {String.t(), String.t()}, elixir: String.t(), otp: String.t(), dep_env: String.t(), config: (String.t(), [String.t()] -> {:ok, term()} | :error), prefer: String.t() | nil }
Functions
The identity of a build's bytes: sha256 over its files' path, sha256 and mode, in path order. Two manifest entries with the same hash install the same files. nil for an entry with a malformed file list, or a path with a NUL or newline, which could pass one file off as another's line.
Lock-closure children of nerves; nerves_bootstrap recompiles them whenever it compiles nerves.