mirror of
https://github.com/cargo-bins/cargo-binstall.git
synced 2025-05-05 03:30:03 +00:00
Mark extract_compressed_from_readable
& unzip
to be pub(super)
Signed-off-by: Jiahao XU <Jiahao_XU@outlook.com>
This commit is contained in:
parent
f82890cba3
commit
b2c34137cc
1 changed files with 2 additions and 2 deletions
|
@ -54,7 +54,7 @@ fn untar<R: Read, V: TarEntriesVisitor>(
|
||||||
/// and only extract ones which filter returns `true`.
|
/// and only extract ones which filter returns `true`.
|
||||||
/// Note that this is a best-effort and it only works when `fmt`
|
/// Note that this is a best-effort and it only works when `fmt`
|
||||||
/// is not `PkgFmt::Bin` or `PkgFmt::Zip`.
|
/// is not `PkgFmt::Bin` or `PkgFmt::Zip`.
|
||||||
pub(crate) fn extract_compressed_from_readable<V: TarEntriesVisitor, R: BufRead>(
|
pub(super) fn extract_compressed_from_readable<V: TarEntriesVisitor, R: BufRead>(
|
||||||
dat: R,
|
dat: R,
|
||||||
fmt: TarBasedFmt,
|
fmt: TarBasedFmt,
|
||||||
path: &Path,
|
path: &Path,
|
||||||
|
@ -99,7 +99,7 @@ pub(crate) fn extract_compressed_from_readable<V: TarEntriesVisitor, R: BufRead>
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
||||||
pub(crate) fn unzip(dat: File, dst: &Path) -> Result<(), BinstallError> {
|
pub(super) fn unzip(dat: File, dst: &Path) -> Result<(), BinstallError> {
|
||||||
debug!("Decompressing from zip archive to `{dst:?}`");
|
debug!("Decompressing from zip archive to `{dst:?}`");
|
||||||
|
|
||||||
let mut zip = ZipArchive::new(dat)?;
|
let mut zip = ZipArchive::new(dat)?;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue