diff options
| author | 魏曹先生 <1992414357@qq.com> | 2026-03-07 19:37:52 +0800 |
|---|---|---|
| committer | 魏曹先生 <1992414357@qq.com> | 2026-03-07 19:37:52 +0800 |
| commit | 9e7c0fd45e169929156bdb317b10d7bb3db65f8b (patch) | |
| tree | 94c1e0e6cafe996b7b7da8dfd6e1ff1a04539cda /src/chunker/rw/storage/write.rs | |
| parent | 22926ce29e3f8e040ec349401aeb6a77f32eae72 (diff) | |
Add callback support to chunk_stream_with and implement stream writing
Diffstat (limited to 'src/chunker/rw/storage/write.rs')
| -rw-r--r-- | src/chunker/rw/storage/write.rs | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/chunker/rw/storage/write.rs b/src/chunker/rw/storage/write.rs index 8b3acc7..9348901 100644 --- a/src/chunker/rw/storage/write.rs +++ b/src/chunker/rw/storage/write.rs @@ -1,4 +1,7 @@ -use std::{collections::HashMap, path::PathBuf}; +use std::{ + collections::HashMap, + path::{Path, PathBuf}, +}; use log::trace; @@ -73,7 +76,7 @@ async fn write_file( } } -pub fn get_index_file_name(path: &PathBuf, ctx: &ButckContext) -> PathBuf { +pub fn get_index_file_name(path: &Path, ctx: &ButckContext) -> PathBuf { let output_file = if let Some(output_file) = &ctx.output_file { return output_file.clone(); } else { |
