Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add map_dir_from_tar and map_file_from_tar #508

Merged
merged 12 commits into from
Feb 19, 2024
Prev Previous commit
Next Next commit
Update dissect/target/filesystem.py
Co-authored-by: Erik Schamper <[email protected]>
JSCU-CNI and Schamper authored Feb 19, 2024
commit 7b8750f8d7194544f01c1704d417dcb186d40cb9
4 changes: 2 additions & 2 deletions dissect/target/filesystem.py
Original file line number Diff line number Diff line change
@@ -1256,8 +1256,8 @@ def map_dir_from_tar(self, vfspath: str, tar_file: str | pathlib.Path, map_singl
file.name = fsutil.basename(vfspath)
self.map_file_entry(vfspath, file)
return

self.mount(vfspath, tfs)
else:
self.mount(vfspath, tfs)

def map_file_from_tar(self, vfspath: str, tar_file: str | pathlib.Path) -> None:
"""Map a single file in a tar archive to the given path in the VFS.