Enum git_checks_core::impl_prelude::CommitError
source · #[non_exhaustive]pub enum CommitError {
Git {
source: GitError,
},
FileName {
source: FileNameError,
},
CommitMetadata {
ref_: CommitId,
output: String,
},
CommitMetadataOutput {
output: String,
},
CommitMessage {
ref_: CommitId,
output: String,
},
RevList {
base_rev: CommitId,
merge_base: Option<CommitId>,
output: String,
},
AncestorCheck {
best_rev: CommitId,
merge_base: CommitId,
output: String,
},
MergeBase {
base: CommitId,
head: CommitId,
output: String,
},
DiffTree {
commit: CommitId,
base: Option<CommitId>,
output: String,
},
DiffPatch {
commit: CommitId,
base: Option<CommitId>,
path: PathBuf,
output: String,
},
}
Expand description
Errors which can occur when working with a commit for a check.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Git
Command preparation failure.
FileName
File name parsing failure.
Fields
§
source: FileNameError
The cause of the error.
CommitMetadata
Failure to extract commit metadata.
CommitMetadataOutput
The commit metadata output did not match the expected format.
CommitMessage
Failure to extract commit message.
RevList
Failure to list revisions in a branch.
Fields
AncestorCheck
Failure to check the ancestory in a branch.
Fields
MergeBase
Failure to determine the merge base between two commits.
Fields
DiffTree
Failure to tree diff of a commit.
Fields
DiffPatch
Failure to get the patch of a commit.
Trait Implementations§
source§impl Debug for CommitError
impl Debug for CommitError
source§impl Display for CommitError
impl Display for CommitError
source§impl Error for CommitError
impl Error for CommitError
source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
The lower-level source of this error, if any. Read more
1.0.0 · source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
source§impl From<CommitError> for RunError
impl From<CommitError> for RunError
source§fn from(source: CommitError) -> Self
fn from(source: CommitError) -> Self
Converts to this type from the input type.
source§impl From<FileNameError> for CommitError
impl From<FileNameError> for CommitError
source§fn from(source: FileNameError) -> Self
fn from(source: FileNameError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for CommitError
impl !RefUnwindSafe for CommitError
impl Send for CommitError
impl Sync for CommitError
impl Unpin for CommitError
impl !UnwindSafe for CommitError
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