git_remote_htree/git/
error.rs1use thiserror::Error;
4
5#[derive(Error, Debug)]
6pub enum Error {
7 #[error("Object not found: {0}")]
8 ObjectNotFound(String),
9
10 #[error("Invalid object type: {0}")]
11 InvalidObjectType(String),
12
13 #[error("Invalid object format: {0}")]
14 InvalidObjectFormat(String),
15
16 #[error("Invalid ref name: {0}")]
17 InvalidRefName(String),
18
19 #[error("Storage error: {0}")]
20 StorageError(String),
21
22 #[error("IO error: {0}")]
23 Io(#[from] std::io::Error),
24}
25
26pub type Result<T> = std::result::Result<T, Error>;