rename imap folder into mailbox

This commit is contained in:
Clément DOUIN
2026-03-02 11:45:27 +01:00
parent 9811619629
commit 0ec0159a28
16 changed files with 36 additions and 208 deletions
+26
View File
@@ -0,0 +1,26 @@
use anyhow::Result;
use clap::Subcommand;
use pimalaya_toolbox::terminal::printer::Printer;
use crate::{account::Account, imap::mailbox::command::MailboxCommand};
/// IMAP CLI (requires `imap` cargo feature).
///
/// This command gives you access to the IMAP CLI API, and allows
/// you to manage IMAP mailboxes: list mailboxes, read messages,
/// add flags etc.
#[derive(Debug, Subcommand)]
#[command(rename_all = "lowercase")]
pub enum ImapCommand {
#[command(subcommand)]
#[command(aliases = ["mboxes", "mbox"])]
Mailboxes(MailboxCommand),
}
impl ImapCommand {
pub fn execute(self, printer: &mut impl Printer, account: Account) -> Result<()> {
match self {
Self::Mailboxes(cmd) => cmd.execute(printer, account),
}
}
}