Skip to main content

git_psect/
error.rs

1use thiserror::Error;
2
3#[derive(Debug, Error)]
4pub enum Error {
5    #[error("{0}")]
6    Validation(String),
7
8    #[error("git error: {0}")]
9    Git(#[from] git2::Error),
10
11    #[error("I/O error: {0}")]
12    Io(#[from] std::io::Error),
13
14    #[error("failed to parse state: {0}")]
15    TomlDe(#[from] toml::de::Error),
16
17    #[error("failed to write state: {0}")]
18    TomlSer(#[from] toml::ser::Error),
19}