From 6cda927d703260b49bc8f75771f33ed386001420 Mon Sep 17 00:00:00 2001 From: FlareFlo Date: Fri, 23 Feb 2024 15:51:36 +0100 Subject: [PATCH] FIx writing output to broken folder path --- src/subcommands/unpack_raw_blk.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/subcommands/unpack_raw_blk.rs b/src/subcommands/unpack_raw_blk.rs index 42d8ef9..a7cbc75 100644 --- a/src/subcommands/unpack_raw_blk.rs +++ b/src/subcommands/unpack_raw_blk.rs @@ -23,6 +23,10 @@ pub fn unpack_raw_blk(args: &ArgMatches) -> Result<()> { .context("Invalid format specified or missing")?; let input = Path::new(input); + if input.is_dir() { + bail!("Directories as input are not implemented yet"); + } + let mut read = fs::read(input)?; let zstd_dict = None; @@ -58,7 +62,7 @@ pub fn unpack_raw_blk(args: &ArgMatches) -> Result<()> { _ => input.to_owned(), }; - output_folder.push(input.file_name().unwrap().to_string_lossy().to_string()); + //output_folder.push(input.file_name().unwrap().to_string_lossy().to_string()); match format.as_str() { "Json" => { output_folder.set_extension("json");