Skip to main content

is_fast_forward

Function is_fast_forward 

Source
pub fn is_fast_forward(
    cwd: &Path,
    old: Option<Hash>,
    new: Hash,
) -> Result<bool, DispatchError>
Expand description

True iff advancing a ref from old to new is a fast-forward (i.e. old is an ancestor of new). A missing old (brand-new ref) and an unchanged ref both count as fast-forwards. Used by push/fetch to pick the git-style summary symbol (.. vs .../(forced update)).