pub trait RepoExt {
    fn get_main_branch(&self) -> Result<Branch<'_>>;
    fn get_main_branch_oid(&self) -> Result<NonZeroOid>;
    fn get_branch_oid_to_names(
        &self
    ) -> Result<HashMap<NonZeroOid, HashSet<ReferenceName>>>; fn get_references_snapshot(&self) -> Result<RepoReferencesSnapshot>; }
Expand description

Helper functions on Repo.

Required Methods

Get the Branch for the main branch for the repository.

Get the OID corresponding to the main branch.

Get a mapping from OID to the names of branches which point to that OID.

The returned branch names include the refs/heads/ prefix, so it must be stripped if desired.

Get the positions of references in the repository.

Implementors