Skip to main content

Crate reth_node_version_build

Crate reth_node_version_build 

Source
Expand description

Stamps reth’s version metadata into a binary from its build script.

Version metadata changes with every commit, and the build timestamp with every build. A library that stamped it would rebuild with every crate that depends on it, so binaries stamp it in their own build script and read it with reth_node_core::reth_version_metadata!.

ⓘ
// build.rs
fn main() -> Result<(), Box<dyn std::error::Error>> {
    reth_node_version_build::emit_version_metadata()
}

Functions§

emit_version_metadata
Emits the version metadata of the binary being built as cargo:rustc-env instructions.