summaryrefslogtreecommitdiff
path: root/src/bin/butck.rs
diff options
context:
space:
mode:
author魏曹先生 <1992414357@qq.com>2026-03-07 19:37:52 +0800
committer魏曹先生 <1992414357@qq.com>2026-03-07 19:37:52 +0800
commit9e7c0fd45e169929156bdb317b10d7bb3db65f8b (patch)
tree94c1e0e6cafe996b7b7da8dfd6e1ff1a04539cda /src/bin/butck.rs
parent22926ce29e3f8e040ec349401aeb6a77f32eae72 (diff)
Add callback support to chunk_stream_with and implement stream writing
Diffstat (limited to 'src/bin/butck.rs')
-rw-r--r--src/bin/butck.rs8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/bin/butck.rs b/src/bin/butck.rs
index 6a81fbb..0d0e102 100644
--- a/src/bin/butck.rs
+++ b/src/bin/butck.rs
@@ -3,11 +3,11 @@ use std::process::exit;
use butchunker::{
chunker::{
context::ButckContext,
- entry::{entry, print_help, print_version},
rw::error::{ButckRWError, ButckRWErrorKind},
},
- log::init_logger,
+ entry::{entry, print_help, print_version},
special_argument, special_flag,
+ utils::log::init_logger,
};
use just_progress::{progress, renderer};
use log::error;
@@ -104,6 +104,10 @@ fn handle_entry_result(r: Result<(), ButckRWError>) {
ButckRWErrorKind::ChunkFailed(_chunk_failed) => error!("Chunk failed"),
ButckRWErrorKind::IOError(error) => error!("IO error: {}", error),
ButckRWErrorKind::InvalidBidxFormat => error!("Invalid bidx format"),
+ ButckRWErrorKind::ChunkingFailed(reason) => error!("Chunking failed: {}", reason),
+ ButckRWErrorKind::IndexFileWriteFailed(reason) => {
+ error!("Failed to write index file: {}", reason)
+ }
},
}
}