mirror of
https://github.com/DarkMatterCore/nxdumptool.git
synced 2024-11-27 04:32:18 +00:00
Proper handling of extracted HFS dumps
This commit is contained in:
parent
4e6f91eaa5
commit
a4c5bf483c
1 changed files with 17 additions and 5 deletions
|
@ -919,6 +919,7 @@ def usbHandleSendFileProperties(cmd_block: bytes) -> int | None:
|
||||||
match ext:
|
match ext:
|
||||||
case "xci": g_logger.info("\tXCI transfer started!")
|
case "xci": g_logger.info("\tXCI transfer started!")
|
||||||
case "bin": g_logger.info("\tGamecard extra data transfer started!")
|
case "bin": g_logger.info("\tGamecard extra data transfer started!")
|
||||||
|
case "fs0": g_logger.info("\tHFS0 raw partition transfer started!")
|
||||||
case "nsp": g_logger.info("\tNSP transfer started!")
|
case "nsp": g_logger.info("\tNSP transfer started!")
|
||||||
case "nca": g_logger.info("\tRaw NCA transfer started!")
|
case "nca": g_logger.info("\tRaw NCA transfer started!")
|
||||||
case "tik": g_logger.info("\tTicket transfer started!")
|
case "tik": g_logger.info("\tTicket transfer started!")
|
||||||
|
@ -933,7 +934,10 @@ def usbHandleSendFileProperties(cmd_block: bytes) -> int | None:
|
||||||
fs = file_size / div
|
fs = file_size / div
|
||||||
if g_extractedFsDumpMode:
|
if g_extractedFsDumpMode:
|
||||||
path_array = filename.split("/")
|
path_array = filename.split("/")
|
||||||
fn = '/'.join(path_array[7:])
|
match path_array[1]:
|
||||||
|
case 'NCA FS': fn = '/'.join(path_array[7:])
|
||||||
|
case 'HFS': fn = '/'.join(path_array[4:])
|
||||||
|
case _: fn = '/'.join(path_array[1:])
|
||||||
elif g_nspTransferMode:
|
elif g_nspTransferMode:
|
||||||
fn = filename
|
fn = filename
|
||||||
g_logger.info(f'\t{fn} ({fs:.2f} {unit})')
|
g_logger.info(f'\t{fn} ({fs:.2f} {unit})')
|
||||||
|
@ -1213,9 +1217,17 @@ def usbHandleStartExtractedFsDump(cmd_block: bytes) -> int:
|
||||||
path_array = extracted_fs_root_path.split('/')
|
path_array = extracted_fs_root_path.split('/')
|
||||||
|
|
||||||
if not g_logVerbose:
|
if not g_logVerbose:
|
||||||
g_logger.info(f'\tExtracted FS dump started!')
|
match path_array[1]:
|
||||||
|
case 'HFS':
|
||||||
|
g_logger.info(f'\tExtracted FS dump from HFS (Gamecard) started!')
|
||||||
|
g_logger.info(f'\nSrc:\t'+'/'.join(path_array[3:]))
|
||||||
|
case 'NCA FS':
|
||||||
|
g_logger.info(f'\tExtracted FS dump from NCA FS (NSP) started!')
|
||||||
g_logger.info(f'\nSrc:\t{path_array[4]}')
|
g_logger.info(f'\nSrc:\t{path_array[4]}')
|
||||||
g_logger.info(f'\t{path_array[5]}, FS section #{path_array[6]}')
|
g_logger.info(f'\t{path_array[5]}, FS section #{path_array[6]}')
|
||||||
|
case _:
|
||||||
|
g__logger.info(f'\tExtracted FS dump from novel source (???) started!')
|
||||||
|
g_logger.info:(f'\nRoot:\t{extracted_fs_root_path}')
|
||||||
g_logger.info(f'Size:\t{g_formattedFileSize:.2f} {g_formattedFileUnit}')
|
g_logger.info(f'Size:\t{g_formattedFileSize:.2f} {g_formattedFileUnit}')
|
||||||
g_logger.info(f'Files:')
|
g_logger.info(f'Files:')
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in a new issue