Easy Unpacker is a lightweight command-line tool written in Go that extracts various archive formats through a simple, unified interface.
- Support for multiple archive formats:
- ZIP (
.zip) - TAR.GZ (
.tar.gz,.tgz) - RAR (
.rar) - 7-Zip (
.7z)
- ZIP (
- Password-protected archive support
- Preserves directory structure during extraction
- Maintains original file permissions
- Clear error reporting
- Automatic directory creation
- Fallback to system utilities when needed
Note: The project is actively being developed with plans to support additional archive formats in the future.
- Go 1.16 or later
- System
unziputility (optional, for advanced ZIP extraction)
# Clone the repository
git clone https://github.com/Id245/easy-unpacker.git
cd easy-unpacker
# Initialize Go modules
go mod init easy-unpacker
# Download dependencies and build
go mod tidy
go build# Clone the repository
git clone https://github.com/Id245/easy-unpacker.git
cd easy-unpacker
# Install dependencies explicitly
go get github.com/nwaples/rardecode
go get github.com/bodgit/sevenzip
# Build the executable
go buildThe Easy Unpacker can be used with positional arguments:
./easy-unpacker <path-to-archive> <destination-directory>- Path to the archive file (required)
- Destination directory for extracted files (required)
-p <password>- Password for encrypted archives (optional)-h- Show help information
If the destination directory doesn't exist, it will be automatically created.
For encrypted archives, use the -p flag followed by the password:
./easy-unpacker -p mypassword ./encrypted.zip ./extractedNote: Password protection is currently supported for ZIP and 7z archives only.
Easy Unpacker uses Go libraries for extraction by default, but will automatically fall back to system utilities in the following cases:
- When dealing with complex encrypted ZIP formats
- When the built-in libraries encounter extraction errors
- For archives with non-standard compression methods
This fallback mechanism requires the corresponding system utilities (unzip for ZIP files) to be installed on your system.
Extract a standard ZIP archive:
./easy-unpacker archive.zip ./extracted_filesExtract a password-protected ZIP archive:
./easy-unpacker -p secretpassword secure_archive.zip ./extracted_files