Skip to main content

reachable_semver_baseline

Function reachable_semver_baseline 

Source
pub fn reachable_semver_baseline(
    project_root: &Path,
) -> Result<Option<Version>, VersionError>
Expand description

As highest_semver_tag, but restricted to tags reachable from HEAD via git tag --merged HEAD — one spawn instead of an O(n) per-tag merge-base --is-ancestor loop, mirroring GitFlow::cleanup_merged’s existing branch --merged precedent in git.rs. This is compute_version’s baseline (D-07).

D-12 coupling: this predicate’s correctness depends on the developmain sync PR being MERGED, not squashed — a squashed sync breaks the ancestry link this --merged check relies on. compute_version’s refusal (D-10, VersionError::UnreachableBaseline) is the mitigation if that discipline is ever violated; 999.52 is the backlog item that would ship a structural repair, deliberately not in this phase.