#[derive(Debug, Clone)]
pub struct CommitSummary {
pub hash: String,
pub summary: String,
pub full_message: Option<String>,
}
#[derive(Debug, Clone, PartialEq, Eq)]
pub enum FileStatus {
Modified,
Added,
Deleted,
Renamed { old: String, new: String },
TypeChange,
Untracked,
Unknown,
}
#[derive(Debug, Clone)]
pub struct Change {
pub path: String,
pub staged: bool,
pub status: FileStatus,
}
#[derive(Debug, Clone, PartialEq, Eq)]
pub enum BranchState {
Local,
UpToDate,
Ahead(usize),
Behind(usize),
Diverged {
ahead: usize,
behind: usize,
},
Gone,
}
#[derive(Debug, Clone)]
pub struct BranchInfo {
pub name: String,
pub current: bool,
pub upstream: Option<String>,
pub state: BranchState,
pub merged: bool,
pub hash: String,
pub subject: String,
pub updated: i64,
}