pub struct Provenance {
pub builder_version: String,
pub build_commit: String,
pub build_dirty: bool,
pub built_at_epoch: u64,
pub source_iso: IsoIdentity,
pub host: HostSpecs,
pub deps: DependencyPins,
pub guest: GuestParams,
}Expand description
Everything build-media records about one installer image build.
Fields§
§builder_version: StringThis crate’s version (CARGO_PKG_VERSION at compile time).
build_commit: StringGit commit the binary was built from (BUILD_GIT_SHA via build.rs;
"unknown" for tarball builds without .git). This is the field
that distinguishes debug runs — the version only changes on bump.
build_dirty: boolUncommitted changes present at compile time (BUILD_GIT_DIRTY).
true means the commit hash alone does NOT reproduce the binary.
built_at_epoch: u64UTC build timestamp (RFC 3339-ish, no chrono dep: seconds epoch).
source_iso: IsoIdentity§host: HostSpecs§deps: DependencyPins§guest: GuestParamsImplementations§
Source§impl Provenance
impl Provenance
Sourcepub fn gather(
win_iso: &Path,
wimlib_bin: &Path,
wim_path: &Path,
arch: Architecture,
qemu_tag: &str,
wimlib_tag: &str,
virtio_iso: Option<&Path>,
username: &str,
locale: &str,
) -> Result<Self>
pub fn gather( win_iso: &Path, wimlib_bin: &Path, wim_path: &Path, arch: Architecture, qemu_tag: &str, wimlib_tag: &str, virtio_iso: Option<&Path>, username: &str, locale: &str, ) -> Result<Self>
Gather provenance for a build-media run. wim_path is the
extracted install.wim (queried via wimlib-imagex info, then the
caller deletes it). Slow steps (ISO hash) print progress.
Best-effort sub-steps degrade to None/empty — only hard I/O
errors propagate. Nine params is the honest shape (every input is
recorded); grouping them would hide what the sidecar captures.
Sourcepub fn sidecar_path(image: &Path) -> PathBuf
pub fn sidecar_path(image: &Path) -> PathBuf
<image>.json next to the installer image.
Sourcepub fn invalidate(image: &Path)
pub fn invalidate(image: &Path)
Invalidate a previous build: delete its sidecar so a crashed/failed rebuild can never report “fresh” over a partial image. Runs at build start (after the freshness skip); missing file is fine.