pub fn changed_lines(
repo: &Path,
base: &str,
) -> Result<BTreeMap<String, BTreeSet<u64>>>Expand description
The new-side lines each file gained in repo’s <base>...HEAD diff, keyed by
repo-relative path. The diff machinery shared by the TS / Rust twins.
<base>...HEAD is the merge-base diff — the changes this branch introduced
(what a PR shows). --unified=0 drops context lines so every + line is a
real addition; --no-renames keeps a rename a delete + an add (the added side
is held to coverage); --relative reports paths relative to repo. Returns an
error if git diff fails (e.g. base names no resolvable ref).