All Projects → wapmorgan → Unifiedarchive

wapmorgan / Unifiedarchive

Licence: mit
UnifiedArchive - an archive manager with a unified way for different formats. Supports all basic (listing, reading, extracting and creation) and specific features (compression level, password-protection). Bundled with console program for working with archives.

Projects that are alternatives of or similar to Unifiedarchive

compress
compress and uncompress for Deno
Stars: ✭ 29 (-88.21%)
Mutual labels:  gzip, zip, tar
Sharpcompress
SharpCompress is a fully managed C# library to deal with many compression types and formats.
Stars: ✭ 1,397 (+467.89%)
Mutual labels:  zip, tar, gzip
Archiver
Easily create & extract archives, and compress & decompress files of various formats
Stars: ✭ 3,373 (+1271.14%)
Mutual labels:  zip, tar, gzip
Swcompression
A Swift framework for working with compression, archives and containers.
Stars: ✭ 110 (-55.28%)
Mutual labels:  zip, tar, gzip
Libarchivejs
Archive library for browsers
Stars: ✭ 145 (-41.06%)
Mutual labels:  zip, tar, gzip
zipstream
A command line tool that allows you to easily share files and directories over the network
Stars: ✭ 49 (-80.08%)
Mutual labels:  gzip, zip, tar
Leanify
lightweight lossless file minifier/optimizer
Stars: ✭ 694 (+182.11%)
Mutual labels:  zip, tar, gzip
Libarchive
Multi-format archive and compression library
Stars: ✭ 1,625 (+560.57%)
Mutual labels:  zip, tar, archiving
ratarmount
Random Access Read-Only Tar Mount
Stars: ✭ 217 (-11.79%)
Mutual labels:  gzip, zip, tar
Bit7z
A C++ static library offering a clean and simple interface to the 7-zip DLLs.
Stars: ✭ 159 (-35.37%)
Mutual labels:  zip, tar, gzip
Turbobench
Compression Benchmark
Stars: ✭ 211 (-14.23%)
Mutual labels:  zip, gzip
Ugrep
🔍NEW ugrep v3.1: ultra fast grep with interactive query UI and fuzzy search: search file systems, source code, text, binary files, archives (cpio/tar/pax/zip), compressed files (gz/Z/bz2/lzma/xz/lz4), documents and more. A faster, user-friendly and compatible grep replacement.
Stars: ✭ 626 (+154.47%)
Mutual labels:  zip, tar
Decompress
Extracting archives made easy
Stars: ✭ 316 (+28.46%)
Mutual labels:  zip, tar
Pgbackrest
Reliable PostgreSQL Backup & Restore
Stars: ✭ 766 (+211.38%)
Mutual labels:  archiving, gzip
Iostreams
IOStreams is an incredibly powerful streaming library that makes changes to file formats, compression, encryption, or storage mechanism transparent to the application.
Stars: ✭ 84 (-65.85%)
Mutual labels:  zip, gzip
Compressing
Everything you need for compressing and uncompressing
Stars: ✭ 268 (+8.94%)
Mutual labels:  tar, gzip
Pyfilesystem2
Python's Filesystem abstraction layer
Stars: ✭ 1,256 (+410.57%)
Mutual labels:  zip, tar
Zippy
Pure Nim implementation of deflate, zlib, gzip and zip.
Stars: ✭ 88 (-64.23%)
Mutual labels:  zip, gzip
Compress
Optimized Go Compression Packages
Stars: ✭ 2,478 (+907.32%)
Mutual labels:  gzip, zip
Afs
Abstract File Storage
Stars: ✭ 126 (-48.78%)
Mutual labels:  zip, tar

UnifiedArchive - an archive manager with a unified way for different formats. Supports all basic (listing, reading, extracting and creation) and specific features (compression level, password-protection). Bundled with console program for working with archives.

Supported formats (depends on installed drivers): zip, 7z, rar, one-file(gz, bz2, xz), tar (tar.gz, tar.bz2, tar.x, tar.Z), and a lot of others.

Latest Stable Version Total Downloads Daily Downloads License Latest Unstable Version

Tests & Quality: Build status Scrutinizer Code Quality Code Coverage

Goal

If on your site/service there is a possibility of usage archives of many types, and you would like to work with them unified, you can use this library.

UnifiedArchive can utilize to handle as many formats as possible:

  • ZipArchive, RarArchive, PharData
  • Pear/Tar
  • 7zip cli program via Gemorroj/Archive7z
  • zip, tar cli programs via Alchemy/Zippy
  • ext-zlib, ext-bz2, ext-xz

Functions & Features

  • Opening an archive with automatic format detection
  • Opening archives encrypted with password (zip, rar, 7z)
  • Getting information about uncompressed size of archive contents
  • Listing archive content
  • Getting details ([un]compressed size, date of modification) of every archived file
  • Reading archived file content as stream (zip, rar, gz, bz2, xz)
  • Extracting archived file content as is or on a disk
  • Appending an archive with new files
  • Removing files from archive
  • Creating new archives with files/directories, adjust compression level (zip, gzip), set passwords (7z, zip)

Quick start

composer require wapmorgan/unified-archive
# install libraries for support: tar.gz, tar.bz2, zip
composer require pear/archive_tar alchemy/zippy
# or if you can, install p7zip package in your OS and SevenZip driver for support a lot of formats (tar.*, zip, rar)
composer require gemorroj/archive7z
# to work with rar natively
pecl install rar

More information about formats support in formats page.

Use it in code:

$archive = \wapmorgan\UnifiedArchive\UnifiedArchive::open('archive.zip'); // archive.rar, archive.tar.bz2
$extracted_size = $archive->countUncompressedFilesSize();
$files_list = $archive->getFileNames();

echo 'Files list: '.array_map(function ($file) { return '- '.$file."\n"; }, $files_list).PHP_EOL;
echo 'Total size after extraction: '.$extracted_size.' byte(s)';

Built-in console archive manager

UnifiedArchive is distributed with a unified console program to manipulate archives. It supports all formats that UnifiedArchive does and can be used to manipulate archives without other software. To show help, launch it:

./vendor/bin/cam --help

Details

  1. Drivers and their formats.
  2. Usage with examples.
  3. Full API description.
  4. Changelog.
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].