Skip to main content

Module build_info

Module build_info 

Source
Expand description

Build-time git provenance captured by build.rs and exposed as compile-time constants.

Two binaries built from different commits of the same crate version are otherwise indistinguishable by crate::VERSION alone; this module carries the commit SHA, dirty flag, commit date, and build timestamp so a resident daemon can report exactly which code it is running (#1374). Every git-derived value is optional: a build made outside a git checkout (a crates.io download or release tarball) simply reports None, and every consumer degrades gracefully. See Provenance.

Structs§

Provenance
Git provenance of the running binary, surfaced on the daemon status/ping wire and in omni-dev --version.

Constants§

GIT_COMMIT_DATE
Committer date of the built commit in strict ISO-8601, or None outside a checkout.
GIT_SHA
Full 40-character commit SHA the binary was built from, or None when built outside a git checkout.
GIT_SHA_SHORT
Abbreviated commit SHA (e.g. a6d304fd), or None outside a checkout.

Functions§

build_timestamp
Build timestamp formatted as an RFC3339 (UTC) string, or None when the build script recorded no clock reading.
git_dirty
Whether the working tree had uncommitted changes at build time.
long_version
Long version string for omni-dev --version: the crate version plus git provenance when available, e.g. 0.36.0 (a6d304fd 2026-07-20, dirty).
provenance
Snapshots this binary’s compile-time provenance into an owned Provenance.