pub enum UpgradeError {
NotRustCrate,
NotGitRepo,
NotInitialized,
ConfigError(ConfigError),
GeneratorError(GeneratorError),
VerifyError(VerifyError),
TemplateError(TemplateError),
MigrationError(MigrationError),
VersionParse(String, Error),
}Expand description
Errors that can occur during the upgrade operation
Variants§
NotRustCrate
Target directory is not a Rust crate (no Cargo.toml found)
NotGitRepo
Target directory is not a git repository (no .git/ found)
NotInitialized
Target directory is not initialized by rust-bucket (no rust-bucket.toml)
ConfigError(ConfigError)
Configuration-related error
GeneratorError(GeneratorError)
Template generation error
VerifyError(VerifyError)
Verification error
TemplateError(TemplateError)
Template extraction error
MigrationError(MigrationError)
Migration error
VersionParse(String, Error)
Version parsing error
Trait Implementations§
Source§impl Debug for UpgradeError
impl Debug for UpgradeError
Source§impl Display for UpgradeError
impl Display for UpgradeError
Source§impl Error for UpgradeError
impl Error for UpgradeError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns 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<ConfigError> for UpgradeError
impl From<ConfigError> for UpgradeError
Source§fn from(source: ConfigError) -> Self
fn from(source: ConfigError) -> Self
Converts to this type from the input type.
Source§impl From<GeneratorError> for UpgradeError
impl From<GeneratorError> for UpgradeError
Source§fn from(source: GeneratorError) -> Self
fn from(source: GeneratorError) -> Self
Converts to this type from the input type.
Source§impl From<MigrationError> for UpgradeError
impl From<MigrationError> for UpgradeError
Source§fn from(source: MigrationError) -> Self
fn from(source: MigrationError) -> Self
Converts to this type from the input type.
Source§impl From<TemplateError> for UpgradeError
impl From<TemplateError> for UpgradeError
Source§fn from(source: TemplateError) -> Self
fn from(source: TemplateError) -> Self
Converts to this type from the input type.
Source§impl From<VerifyError> for UpgradeError
impl From<VerifyError> for UpgradeError
Source§fn from(source: VerifyError) -> Self
fn from(source: VerifyError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl !RefUnwindSafe for UpgradeError
impl !UnwindSafe for UpgradeError
impl Freeze for UpgradeError
impl Send for UpgradeError
impl Sync for UpgradeError
impl Unpin for UpgradeError
impl UnsafeUnpin for UpgradeError
Blanket Implementations§
impl<T> Any for Twhere
T: Any,
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> 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