Skip to main content

mixtape_cli/
error.rs

1//! CLI-specific error types
2
3use thiserror::Error;
4
5/// Errors that can occur during CLI operations
6#[derive(Debug, Error)]
7pub enum CliError {
8    /// Agent execution error
9    #[error("Agent error: {0}")]
10    Agent(#[from] mixtape_core::AgentError),
11
12    /// Session storage error
13    #[error("Session error: {0}")]
14    Session(#[from] mixtape_core::SessionError),
15
16    /// Readline/input error
17    #[error("Input error: {0}")]
18    Readline(#[from] rustyline::error::ReadlineError),
19
20    /// IO error (filesystem, stdout, etc.)
21    #[error("IO error: {0}")]
22    Io(#[from] std::io::Error),
23
24    /// Shell command execution error
25    #[error("Shell command failed: {0}")]
26    ShellCommand(String),
27}