pub async fn hunks_between(
root: &Path,
git_ref: &str,
tip: Option<&str>,
wanted: fn(&Path) -> bool,
) -> Result<Vec<Hunk>, GitError>Expand description
Hunks between git_ref and an explicit tip, or HEAD when tip is
None.
The tip exists for the pre-push hook. git hands a hook the ref being
pushed, which need not be the checked-out branch, and reviewing HEAD
instead means the pushed code is never seen - so the hook passes the ref’s
own oid here.