summaryrefslogtreecommitdiff
path: root/src/error.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/error.rs')
-rw-r--r--src/error.rs17
1 files changed, 16 insertions, 1 deletions
diff --git a/src/error.rs b/src/error.rs
index 77eab69..dc132f4 100644
--- a/src/error.rs
+++ b/src/error.rs
@@ -1,6 +1,6 @@
1pub type Result<T> = std::result::Result<T, Error>; 1pub type Result<T> = std::result::Result<T, Error>;
2 2
3#[derive(Debug, PartialEq, Eq, thiserror::Error)] 3#[derive(Debug, thiserror::Error)]
4pub enum Error { 4pub enum Error {
5 #[error("unknown custom directory '{0}'")] 5 #[error("unknown custom directory '{0}'")]
6 CustomDirectory(String), 6 CustomDirectory(String),
@@ -16,4 +16,19 @@ pub enum Error {
16 16
17 #[error("Only exactly one user allowed in config")] 17 #[error("Only exactly one user allowed in config")]
18 MultiUser, 18 MultiUser,
19
20 #[error("OsString couldn't be converted to string")]
21 InvalidOsString,
22
23 #[error("json: {source}")]
24 SerdeJson {
25 #[from]
26 source: serde_json::Error,
27 },
28
29 #[error("io: {source}")]
30 Io {
31 #[from]
32 source: std::io::Error,
33 }
19} 34}