Skip to main content

ref_exists

Function ref_exists 

Source
pub fn ref_exists(reference: &str) -> bool
Expand description

Whether a ref (branch, remote-tracking ref, SHA) resolves locally.

Local lookup only (rev-parse --verify) — no network. Use after a fetch to check e.g. origin/<branch> without another round-trip.