pub enum RepositoryChangeStatusWithError {
UpToDate,
NoRepository,
UncommittedChanges {
num_changes: usize,
},
Error {
reason: GrassError,
},
Unknown,
}Expand description
Describes the status of a repository.
The status is related to whether or not there are changes.
Variants§
UpToDate
All changes have been committed.
NoRepository
No repository has been initialized.
UncommittedChanges
A repository has been initialized, but there are uncommitted changes.
num_changes is not strongly defined, this number may change between versions.
It has no real meaning, and should only be used for generic estimates.
Error
The status is unkown due to an error.
Fields
reason: GrassErrorUnknown
This repository has an unknown status.
This is only applicable if the unkown status is within the expected behavior of the implementation. For example, if an implementation has to synchronize in the background, then it may result in an unkown status.
This means that unknown doesn’t mean something is wrong, although it may be.
If the status is unknown due to an error, use Error1 instead.
[crate::dev::strategy::git::RepositoryChangeStatus::Error] ↩
Trait Implementations§
Source§impl From<RepositoryChangeStatus> for RepositoryChangeStatusWithError
impl From<RepositoryChangeStatus> for RepositoryChangeStatusWithError
Source§fn from(value: RepositoryChangeStatus) -> Self
fn from(value: RepositoryChangeStatus) -> Self
Source§impl<T: Into<GrassError>> From<Result<RepositoryChangeStatus, T>> for RepositoryChangeStatusWithError
impl<T: Into<GrassError>> From<Result<RepositoryChangeStatus, T>> for RepositoryChangeStatusWithError
Source§fn from(value: Result<RepositoryChangeStatus, T>) -> Self
fn from(value: Result<RepositoryChangeStatus, T>) -> Self
Source§impl<T: Into<GrassError>> From<T> for RepositoryChangeStatusWithError
impl<T: Into<GrassError>> From<T> for RepositoryChangeStatusWithError
Source§impl PartialEq for RepositoryChangeStatusWithError
impl PartialEq for RepositoryChangeStatusWithError
Source§fn eq(&self, other: &RepositoryChangeStatusWithError) -> bool
fn eq(&self, other: &RepositoryChangeStatusWithError) -> bool
self and other values to be equal, and is used by ==.impl Eq for RepositoryChangeStatusWithError
impl StructuralPartialEq for RepositoryChangeStatusWithError
Auto Trait Implementations§
impl Freeze for RepositoryChangeStatusWithError
impl RefUnwindSafe for RepositoryChangeStatusWithError
impl Send for RepositoryChangeStatusWithError
impl Sync for RepositoryChangeStatusWithError
impl Unpin for RepositoryChangeStatusWithError
impl UnwindSafe for RepositoryChangeStatusWithError
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
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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>
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>
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