pub struct GitRepo { /* private fields */ }Implementations§
Source§impl GitRepo
impl GitRepo
Sourcepub fn open<P: AsRef<Path>>(path: Option<P>) -> Result<Self>
pub fn open<P: AsRef<Path>>(path: Option<P>) -> Result<Self>
Open a repository at path, or current dir if None
pub fn path(&self) -> &Path
pub fn resolve_range( &self, since: Option<&str>, until: Option<&str>, ) -> Result<DateRange>
pub fn collect_commits( &self, range: &DateRange, include_merges: bool, binary: bool, progress: bool, ) -> Result<Vec<CommitStats>>
pub fn get_commit_info(&self, commit_id: &str) -> Result<CommitInfo>
Sourcepub fn list_commit_ids(
&self,
range: &DateRange,
include_merges: bool,
) -> Result<Vec<ObjectId>>
pub fn list_commit_ids( &self, range: &DateRange, include_merges: bool, ) -> Result<Vec<ObjectId>>
List commit IDs within range, honoring include_merges, without computing diffs.
Sourcepub fn compute_commit_stats_for(
&self,
commit_id: ObjectId,
binary: bool,
) -> Result<CommitStats>
pub fn compute_commit_stats_for( &self, commit_id: ObjectId, binary: bool, ) -> Result<CommitStats>
Compute commit stats for a single commit by ID, using first parent when present.
Auto Trait Implementations§
impl !Freeze for GitRepo
impl !RefUnwindSafe for GitRepo
impl !Sync for GitRepo
impl !UnwindSafe for GitRepo
impl Send for GitRepo
impl Unpin for GitRepo
impl UnsafeUnpin for GitRepo
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more