♻️ refactor(core): rename eol_cmd to eol_action

- clarifies the file's purpose as defining actions related to EOL handling rather than just commands
This commit is contained in:
Jeremiah Russell
2025-10-09 14:02:33 +01:00
committed by Jeremiah Russell
parent fdc36096dc
commit a317372d3a

22
src/eol_action.rs Normal file
View File

@@ -0,0 +1,22 @@
use std::fmt;
/// End of life command
/// - Trash - move the message to the trash to be automatically deleted by Google
/// - Delete - delete the message immediately without allowing rescue from trash
#[derive(Debug, Default)]
pub enum EolAction {
#[default]
/// Move the message to the trash
Trash,
/// Delete the message immediately
Delete,
}
impl fmt::Display for EolAction {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
match self {
EolAction::Trash => write!(f, "trash"),
EolAction::Delete => write!(f, "delete"),
}
}
}