pub enum ScissorsError {
NoEditor,
EditorFailed {
code: i32,
draft_path: PathBuf,
},
SilentFailure {
elapsed_ms: u32,
draft_path: PathBuf,
},
Io(Error),
}Expand description
Errors from approve_in_editor. The failure cases preserve the draft file
and report its path so the user can recover their work.
Variants§
Trait Implementations§
Source§impl Debug for ScissorsError
impl Debug for ScissorsError
Source§impl Display for ScissorsError
impl Display for ScissorsError
Source§impl Error for ScissorsError
impl Error for ScissorsError
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<Error> for ScissorsError
impl From<Error> for ScissorsError
Source§impl From<ScissorsError> for FileError
Total, lossless conversion of a stdin-mode editor error onto the file-mode
surface. The stdin-only draft_path is dropped (file mode keeps no draft;
the sidecar path is reported by FileError::Persist instead).
impl From<ScissorsError> for FileError
Total, lossless conversion of a stdin-mode editor error onto the file-mode
surface. The stdin-only draft_path is dropped (file mode keeps no draft;
the sidecar path is reported by FileError::Persist instead).
Source§fn from(e: ScissorsError) -> Self
fn from(e: ScissorsError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl !RefUnwindSafe for ScissorsError
impl !UnwindSafe for ScissorsError
impl Freeze for ScissorsError
impl Send for ScissorsError
impl Sync for ScissorsError
impl Unpin for ScissorsError
impl UnsafeUnpin for ScissorsError
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