mirror of
https://github.com/ouch-org/ouch.git
synced 2025-06-07 12:05:46 +00:00
fix clippy warnings
This commit is contained in:
parent
be0b68aee5
commit
eac0a0687a
@ -11,7 +11,7 @@ use crate::utils::colors::*;
|
|||||||
|
|
||||||
#[allow(missing_docs)]
|
#[allow(missing_docs)]
|
||||||
/// All errors that can be generated by `ouch`
|
/// All errors that can be generated by `ouch`
|
||||||
#[derive(Debug, PartialEq)]
|
#[derive(Debug, PartialEq, Eq)]
|
||||||
pub enum Error {
|
pub enum Error {
|
||||||
/// Not every IoError, some of them get filtered by `From<io::Error>` into other variants
|
/// Not every IoError, some of them get filtered by `From<io::Error>` into other variants
|
||||||
IoError { reason: String },
|
IoError { reason: String },
|
||||||
@ -42,7 +42,7 @@ pub type Result<T> = std::result::Result<T, Error>;
|
|||||||
pub type CowStr = Cow<'static, str>;
|
pub type CowStr = Cow<'static, str>;
|
||||||
|
|
||||||
/// Pretty final error message for end users, crashing the program after display.
|
/// Pretty final error message for end users, crashing the program after display.
|
||||||
#[derive(Clone, Debug, Default, PartialEq)]
|
#[derive(Clone, Debug, Default, PartialEq, Eq)]
|
||||||
pub struct FinalError {
|
pub struct FinalError {
|
||||||
/// Should be made of just one line, appears after the "\[ERROR\]" part
|
/// Should be made of just one line, appears after the "\[ERROR\]" part
|
||||||
title: CowStr,
|
title: CowStr,
|
||||||
|
@ -17,7 +17,7 @@ use crate::{
|
|||||||
utils::colors,
|
utils::colors,
|
||||||
};
|
};
|
||||||
|
|
||||||
#[derive(Debug, PartialEq, Clone, Copy)]
|
#[derive(Debug, PartialEq, Eq, Clone, Copy)]
|
||||||
/// Determines if overwrite questions should be skipped or asked to the user
|
/// Determines if overwrite questions should be skipped or asked to the user
|
||||||
pub enum QuestionPolicy {
|
pub enum QuestionPolicy {
|
||||||
/// Ask the user every time
|
/// Ask the user every time
|
||||||
@ -28,7 +28,7 @@ pub enum QuestionPolicy {
|
|||||||
AlwaysNo,
|
AlwaysNo,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Debug, PartialEq, Clone, Copy)]
|
#[derive(Debug, PartialEq, Eq, Clone, Copy)]
|
||||||
/// Determines which action is being questioned
|
/// Determines which action is being questioned
|
||||||
pub enum QuestionAction {
|
pub enum QuestionAction {
|
||||||
/// question called from a compression function
|
/// question called from a compression function
|
||||||
|
Loading…
x
Reference in New Issue
Block a user