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-envinstructions.