enum RepoPresence {
Present,
Absent,
Unusable,
}Expand description
Whether a git repository is reachable from a scan cwd, and whether git could answer the question at all. The third variant matters: “git told me there is no repo” and “git would not run” must not collapse together, or a missing git binary reads as a non-repo and silently suppresses the GIT section instead of reporting itself.
Variants§
Present
A repo exists here, even if it has no commits yet.
Absent
git ran, reported no repository, and there is no .git on disk
to contradict it.
Unusable
git could not be run, or it refused a checkout that does have a
.git. Either way the question went unanswered, so the caller
must report rather than suppress.
Trait Implementations§
Source§impl Clone for RepoPresence
impl Clone for RepoPresence
impl Copy for RepoPresence
Source§impl Debug for RepoPresence
impl Debug for RepoPresence
impl Eq for RepoPresence
Source§impl PartialEq for RepoPresence
impl PartialEq for RepoPresence
impl StructuralPartialEq for RepoPresence
Auto Trait Implementations§
impl Freeze for RepoPresence
impl RefUnwindSafe for RepoPresence
impl Send for RepoPresence
impl Sync for RepoPresence
impl Unpin for RepoPresence
impl UnsafeUnpin for RepoPresence
impl UnwindSafe for RepoPresence
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.