Unified interface for tar, zip, sevenzip, and rar files
Project description
Unified interface for tar, zip, sevenzip, and rar files
Table Of Contents
About
archivefile
is a wrapper around tarfile
, zipfile
, py7zr
, and rarfile
. It simplifies archive management tasks by providing a unified interface.
Installation
archivefile
is available on PyPI, so you can simply use pip to install it.
pip install archivefile
Usage
from archivefile import ArchiveFile
with ArchiveFile("archive.tar", "w") as archive:
archive.extract("member.txt") # Extract a single member of the archive
with ArchiveFile("archive.tar", "w") as archive:
archive.extractall(destination="~/output") # Extract all members
with ArchiveFile("archive.tar") as archive:
archive.read_text("member.txt") # Read a member of the archive
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
archivefile-0.1.0.tar.gz
(9.8 kB
view hashes)
Built Distribution
Close
Hashes for archivefile-0.1.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 1db6cd2e289406e9467a6c3c740ee7110f35c6bc2d70f55e31cf809c39b7197c |
|
MD5 | 67bdb25c7b4f1712650955850b7e1e69 |
|
BLAKE2b-256 | 1c3813b3ddac400dd3376d34b681adf713f89dfe0c8a4cc779b9e9e4fdc1574c |