summaryrefslogtreecommitdiff
path: root/src/error.rs
diff options
context:
space:
mode:
authorfxqnlr <[email protected]>2024-09-06 10:56:30 +0200
committerfxqnlr <[email protected]>2024-09-06 10:56:30 +0200
commit3e1cb020d5449849b37874f91cadfa4a9c878747 (patch)
treec5503a137c77ac33c1e7ddfd4087cc994b51a43b /src/error.rs
downloadarbs-3e1cb020d5449849b37874f91cadfa4a9c878747.tar
arbs-3e1cb020d5449849b37874f91cadfa4a9c878747.tar.gz
arbs-3e1cb020d5449849b37874f91cadfa4a9c878747.zip
initial commit, can save index, no modification check
Diffstat (limited to 'src/error.rs')
-rw-r--r--src/error.rs19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/error.rs b/src/error.rs
new file mode 100644
index 0000000..77eab69
--- /dev/null
+++ b/src/error.rs
@@ -0,0 +1,19 @@
1pub type Result<T> = std::result::Result<T, Error>;
2
3#[derive(Debug, PartialEq, Eq, thiserror::Error)]
4pub enum Error {
5 #[error("unknown custom directory '{0}'")]
6 CustomDirectory(String),
7
8 #[error("invalid directory index '{0}'")]
9 InvalidIndex(String),
10
11 #[error("no directory index given")]
12 NoIndex,
13
14 #[error("invalid directory '{0}'")]
15 InvalidDirectory(String),
16
17 #[error("Only exactly one user allowed in config")]
18 MultiUser,
19}