use thiserror::Error;
#[derive(Debug, Error)]
pub enum WorktreeError {
#[error("git command failed: {0}")]
GitFailed(String),
#[error("worktree not found: {0}")]
NotFound(String),
#[error("worktree already exists: {0}")]
AlreadyExists(String),
#[error("max worktrees reached: {current}/{max}")]
MaxReached {
current: u32,
max: u32,
},
#[error("invalid worktree path: {0}")]
InvalidPath(String),
#[error("invalid session id: {0}")]
InvalidSessionId(String),
#[error("io error: {0}")]
Io(#[from] std::io::Error),
}