summaryrefslogtreecommitdiff
path: root/src/generation.rs
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2021-11-27 09:57:54 +0200
committerLars Wirzenius <liw@liw.fi>2021-11-27 11:21:16 +0200
commit9dcd23354ec74daf4000ec40bd52a33341a16cd8 (patch)
tree7a88381b98637fa723f699feb6ad40a2725b1ace /src/generation.rs
parent8d00d6e452638cbb5418887d0057b95d777a8fa0 (diff)
downloadobnam2-9dcd23354ec74daf4000ec40bd52a33341a16cd8.tar.gz
feat! turn errors from backup root directory into errors
Previously an error from, say, a missing backup root directory was reported to the user as a warning. Turn it into an error. However, errors reading a file or directory inside the backup root should still be just a warning. Sponsored-by: author
Diffstat (limited to 'src/generation.rs')
-rw-r--r--src/generation.rs3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/generation.rs b/src/generation.rs
index 33750ca..6613c02 100644
--- a/src/generation.rs
+++ b/src/generation.rs
@@ -53,6 +53,9 @@ pub struct NascentGeneration {
#[derive(Debug, thiserror::Error)]
pub enum NascentError {
+ #[error("Could not back up a backup root directory: {0}: {1}")]
+ BackupRootFailed(PathBuf, crate::fsiter::FsIterError),
+
#[error(transparent)]
LocalGenerationError(#[from] LocalGenerationError),