Deliver the repo-side release-engineering slice of marqdo-view#19 (formal release remains a maintainer action): - `build.rs` embeds `MARQDO_BUILD_SOURCE_SHA`; `marqdo-view --version` now prints the long identity `marqdo-view 0.3.0 (source <40-hex|dev>)` while `-V` keeps the short product line. MQDH/release records can bind an asset to the tested commit instead of guessing from a file name. - `docs/RELEASE.md` records the release identity, platform matrix (Linux x86_64 supported; macOS/Windows UNVERIFIED; Linux aarch64 unsupported), the tool-bundle/archive/SHA-256/SHA256SUMS asset contract, same-SHA gates, maintainer-only publication (CI only notifies the root reconcile) and the MQDH consumption contract (public Analysis 3/Observation 1, `--embed`, Observation-bound export, no private protocol). - No change to reader/export/execution behavior, protocols or dependencies. Formal tag/release and MQDH same-candidate acceptance remain UNVERIFIED and must not be inferred from this change.
22 lines
829 B
Rust
22 lines
829 B
Rust
//! Embed the release source commit when the build supplies it.
|
|
//!
|
|
//! `marqdo-view --version` reports the short product version; the long version
|
|
//! also names the exact source commit so MQDH/release records can bind a View
|
|
//! asset to the tested commit. A development build reports `dev` instead of
|
|
//! guessing.
|
|
|
|
fn main() {
|
|
println!("cargo:rerun-if-env-changed=MARQDO_BUILD_SOURCE_SHA");
|
|
let sha = std::env::var("MARQDO_BUILD_SOURCE_SHA")
|
|
.ok()
|
|
.map(|value| value.trim().to_string())
|
|
.filter(|value| {
|
|
value.len() == 40
|
|
&& value
|
|
.chars()
|
|
.all(|ch| ch.is_ascii_hexdigit() && !ch.is_ascii_uppercase())
|
|
})
|
|
.unwrap_or_else(|| "dev".to_string());
|
|
println!("cargo:rustc-env=MARQDO_VIEW_SOURCE_SHA={sha}");
|
|
}
|