GeeZipX
A cross-platform compression and decompression CLI tool, built with Rust.
One tool to compress, decompress, and inspect archives across formats.
Features
- Multi-format -- ZIP, TAR, TAR.GZ/TGZ, TAR.ZST/TZST, TAR.XZ/TXZ, GZIP/GZ, Zstandard/ZST, XZ, LZMA (read/write), 7Z (read-only), and RAR (read-only)
- Streaming I/O -- process large files with bounded memory usage
- Live progress bars -- real-time speed, ETA, and per-file status on TTY
- Cancel-safe -- graceful Ctrl+C with partial-file cleanup; double Ctrl+C force-kill
- Auto-format detection -- magic-byte recognition with extension-based fallback
- Compression levels --
--level 0-9for gzip/tar.gz/xz/lzma/tar.xz;--level 0-22for zstd/tar.zst - Clobber controls --
--no-clobberto skip existing files,--forceto overwrite - Zip Slip protection -- blocks path-traversal attacks in all archive formats
- JSON output --
list --jsonfor machine-readable inspection;test --jsonfor programmatic integrity results - Shell completions -- bash, zsh, fish, PowerShell, elvish
- ZIP AES-256 encryption --
--password,--password-file, or--password-stdin(ZIP and 7z read-only) - Cross-platform -- Linux, macOS, Windows (3-platform CI)
- Single binary -- no runtime dependencies,
cargo installready - Multi-threaded compression --
-j/--jobsfor parallel compression (tar.gz via gzp/pigz-style, zstd/tar.zst via native zstdmt)
Status
Phase 1 (CLI MVP) is complete and mature. All core subcommands (compress, decompress, list, test, completions) work for all supported formats.
Phase 2 (Desktop GUI via Tauri) is now the active development focus.
See docs/GUI_MVP_PLAN.md for current planning and task breakdown.
| Milestone | Theme | Status |
|---|---|---|
| M1 | Project skeleton + core engine library | Complete |
| M2 | CLI basic commands | Complete |
| M3 | Streaming / progress / polish | Complete |
| M4 | CI / testing / release | Complete |
Install
From source
# Clone and build
# The binary is at ./target/release/geezipx
Via cargo
Pre-built binaries
For releases that include pre-built artifacts, binaries use the following names:
| Platform | Artifact |
|---|---|
| Linux (x86_64) | geezipx-linux-x86_64.tar.gz |
| macOS (x86_64) | geezipx-macos-x86_64.tar.gz |
| Windows (x86_64) | geezipx-windows-x86_64.zip |
Each artifact is published with a .sha256 checksum file and a combined SHA256SUMS file for verification.
# Download and verify (Linux example)
Note: The release workflow is configured to upload pre-built binaries for future
v*tag releases. Existing releases may be source-only; check the specific GitHub Release page for available artifacts.
Prerequisites
- Rust stable toolchain (see
.rust-toolchain.toml)
Quick Start
# Compress a file to ZIP
# Compress with explicit format
# Compress a directory recursively to tar.gz
# Decompress an archive (auto-detects format)
# Decompress gzip to stdout
# Compress with zstandard
# Decompress zstandard to stdout
# Multi-threaded zstd compression (4 workers)
# Glob pattern expansion (all .rs files in src/)
# Compress directory into tar.zst archive
# Decompress tar.zst archive
# List contents of tar.zst archive
# Decompress to a specific directory
# Decompress skipping existing files
# Decompress overwriting existing files
# List archive contents
# List archive contents as JSON
# Test archive integrity (without extracting to disk)
# Test with JSON output
Pipe data through stdin/stdout (single-stream and tar-based formats)
echo "Hello" | geezipx compress --stdin -f gz -o hello.gz echo "Hello" | geezipx compress --stdin -f gz --stdout > hello.gz cat hello.txt | geezipx compress --stdin -f zst -o hello.txt.zst cat hello.txt.gz | geezipx decompress --stdin -f gz --stdout > hello.txt cat hello.txt.gz | geezipx decompress --stdin -f gz -o outdir # writes outdir/output geezipx compress hello.txt -f gz --stdout > hello.gz # file to stdout
--- tar-based pipeline examples (raw tar stdin/stdout) ---
cat raw.tar | geezipx compress --stdin -f tar.gz -o archive.tar.gz # compress raw tar to file tar cf - mydir/ | geezipx compress --stdin -f tar.zst -o mydir.tar.zst # pipe tar directly geezipx decompress archive.tar.gz --stdout | tar tf - # decompress to raw tar stream geezipx decompress archive.tar.xz --stdout > raw.tar # extract compression layer only
Usage
Global Flags
| Flag | Description |
|---|---|
--no-progress |
Disable progress bar (ideal for scripts) |
-v, --verbose |
Log each file as it's processed |
compress — Create archives
| Option | Description |
|---|---|
-o, --output |
|
-f, --format |
Format: zip, tar, tar.gz, tgz, gz, gzip, tar.zst, tzst, zst, zstd, tar.xz, txz, xz, lzma (inferred from extension if omitted, defaults to zip) |
-r, --recursive |
Recursively add directories |
-L,--level| Compression level 0-9 (gzip/tar.gz/xz/tar.xz, default: 6); 0-22 (zstd/zst/tar.zst/tzst, default: zstd default) | |-j,--jobs| Worker threads: 1 (default, single-threaded), 0 (auto, use all CPUs), or N (explicit). Effective for tar.gz (gzp parallel gzip) and zstd/tar.zst (native zstdmt); tar.xz/zip/xz/lzma accept but ignore for forward compat. Note: tar.gz--jobsdoes not apply in--stdinsingle-stream mode, only in archive mode ||--password| Encrypt ZIP with AES-256 (ZIP format only). Use--password-fileto read the password from a file, or--password-stdinto read from stdin. These three options are mutually exclusive. For scripting, prefer--password-fileor--password-stdinto avoid exposing the password in the process list | |--stdin| Read uncompressed data from stdin (gzip/zstd/xz/lzma single-stream and tar.gz/tar.zst/tar.xz raw tar; requires--format; mutually exclusive with input files) |--stdout| Write compressed data to stdout (gzip/zstd/xz/lzma single-stream and tar.gz/tar.zst/tar.xz raw tar; requires--format; mutually exclusive with--output)
decompress — Extract archives
Auto-detects the format via magic bytes (with extension fallback).
| Option | Description |
|---|---|
-o, --output-dir |
Output directory (default: current directory) |
--stdout |
Decompress to stdout. Single-stream (gzip/zstd/xz/lzma): outputs original content. Tar-based (tar.gz/tar.zst/tar.xz): outputs raw tar stream. Errors on multi-file archives (zip/tar/7z/rar) |
--stdin |
Read compressed data from stdin (gzip/zstd/xz/lzma and tar.gz/tar.zst/tar.xz; requires --format; mutually exclusive with archive file) |
-f, --format |
|
--no-clobber |
Skip files that already exist |
--force |
Overwrite existing files (default; mutually exclusive with --no-clobber) |
--password |
list — Inspect archives
Displays a table of entries with path, size, compressed size, ratio, and modification time.
| Option | Description |
|---|---|
-j, --json |
Output as a JSON array |
--password |
Password for decrypting encrypted archives (ZIP, 7z, and RAR). Use --password-file to read from a file, or --password-stdin to read from stdin. These three options are mutually exclusive |
Note: Dangerous paths (absolute paths, path-traversal entries, Windows device paths) in archives emit a warning on stderr. The stdout/JSON output remains clean and unaffected.
test — Verify archive integrity
Reads every entry to completion without extracting to disk and reports whether the archive is structurally sound.
Supports CRC-32 verification for zip archives.
A corrupted archive results in a non-zero exit code.
| Option | Description |
|---|---|
-j, --json |
Output as JSON with ok boolean |
--password |
completions — Shell completion scripts
Supported shells: bash, zsh, fish, powershell, elvish.
Example:
# Bash
# Zsh
# Fish
After installing, restart your shell or source the file for tab-completion on subcommands, flags, and arguments.
Project Structure
geezipx/
├── AGENTS.md # AI agent collaboration guide
├── CHANGELOG.md # Release changelog
├── Cargo.toml # Workspace root
├── crates/
│ ├── core/ # Compression/decompression engine library
│ │ └── src/
│ │ ├── archive/ # ZIP, TAR, TAR.GZ, TAR.ZST, TAR.XZ, GZIP, ZSTD, XZ, LZMA implementations
│ │ ├── config.rs # Compression options (CompressOptions, --jobs/--level)
│ │ ├── detect.rs # Format detection (magic bytes + extension)
│ │ ├── error.rs # Unified error types (GeeZipError)
│ │ └── io.rs # Streaming I/O wrappers (ProgressReader, etc.)
│ └── cli/ # CLI binary (clap-based, thin shell over core)
│ └── src/
│ ├── commands/ # compress / decompress / list / test
│ ├── render/ # Progress bar rendering
│ └── signal.rs # Ctrl+C cancellation
├── docs/ # Product & architecture documentation
├── scripts/ # Build, CI, and interoperability test scripts
├── crates/cli/tests/ # CLI integration and streaming smoke tests
├── .github/workflows/ # CI, audit, and benchmark workflows
├── deny.toml # cargo-deny configuration
└── .rust-toolchain.toml # Rust toolchain pin
Architecture
GeeZipX follows a layered workspace architecture:
┌─────────────┐ ┌─────────────┐
│ cli (bin) │ │ gui-tauri │ ← Frontend layers (CLI / future GUI)
└──────┬──────┘ └──────┬──────┘
│ │
└───────┬────────┘
│ depends on
┌───────▼────────┐
│ core (lib) │ ← Core engine: all archive/compression logic
│ ─ pure data │ - No I/O assumptions
│ ─ no terminal │ - Reusable by CLI and future Tauri GUI
└────────────────┘
The core library handles all format logic through unified ArchiveReader / ArchiveWriter traits. The CLI is a thin shell that handles argument parsing and progress display only. This design ensures the same compression engine will power the future Tauri desktop GUI without duplication.
Development
Prerequisites
- Rust stable (install via rustup)
- C++ compiler toolchain (required for default RAR support; skip RAR with
--no-default-features)
Build & Test
# Build all workspace crates
# Run all tests (unit + integration)
# Release build
# Check formatting
# Run clippy (strict mode)
# Generate documentation
RAR support
RAR archive support is read-only and enabled by default. The
unrar crate links against the RARLAB freeware
UnRAR source (requires a C++ compiler).
# Default build (RAR included)
# Run tests with all features (RAR included)
If you want to build without RAR support (e.g., in an environment without a C++ compiler):
Note:
cargo publishandcargo installinclude RAR support by default. If you cannot use the C++ compiler requirement, build with--no-default-features.
Benchmarks
Criterion benchmarks are configured and available for manual runs:
# Verify benchmarks compile
# Run full benchmarks
Benchmarks cover gzip throughput (4 levels x 2 sizes) and archive throughput (tar.gz, TarZst, ZIP round-trip).
Note: Benchmarks are advisory only. GitHub-hosted runner variance makes hard thresholds unreliable. No further investment in benchmark baselines or CI performance gates is planned.
Interoperability Tests
Code coverage is tracked via cargo-tarpaulin as an informational signal (no fail-under threshold). A scheduled CI workflow generates HTML and JSON reports on push to main and uploads them as build artifacts.
# Generate coverage report (output: coverage/tarpaulin-report.html and .json)
# Standard checks against system tar, unzip, gzip
# Heavy stress mode (256 MB gzip, 1000-file tar.gz)
GEEZIPX_INTEROP_STRESS=1
Release Build Verification
# Full quality gate (run before committing)
&& \
&& \
&& \
Release Artifact Dry-Run
Before tagging a release, you can trigger the Release workflow
manually via workflow_dispatch with dry_run: true (default). This builds, packages,
and verifies artifacts across all three platforms without creating a GitHub Release,
allowing you to catch build issues before pushing a v* tag.
The workflow job summary includes artifact integrity checks (presence, size, SHA256)
and the combined SHA256SUMS file.
Roadmap
Phase 1 (CLI MVP) — Complete and Mature ✓
All core features and enhancements are implemented and verified:
- ZIP / TAR / TAR.GZ / TAR.ZST / TAR.XZ / GZIP / ZSTD / XZ / LZMA read/write
- Streaming I/O with bounded memory usage
- Progress bars with indicatif
- Ctrl+C graceful cancellation
- Auto-format detection (magic bytes + extension)
- Clobber protection (
--no-clobber/--force) - Zip Slip path traversal protection
- Shell completions (5 shells)
-
list --jsonmachine-readable output -
testarchive integrity verification with JSON output - 400+ tests (unit + integration + interop + streaming smoke)
- 3-platform CI (Linux/macOS/Windows)
- cargo-deny security audit
- Criterion benchmarks (advisory, no hard gate)
- crates.io release
- Multi-threaded compression (
-j/--jobsfor tar.gz, zstd/tar.zst) - ZIP AES-256 password encryption
- 7z read-only support
- RAR read-only support
- stdin/stdout pipeline (single-stream + tar-based formats)
Phase 2 (Desktop GUI via Tauri) — Current Development 🚀
- Tauri + frontend framework project skeleton
- Core engine binding via Tauri command bridge
- File browser / drag-and-drop interface
- Compress / decompress task management
- Live progress display (via Tauri event emit)
- Cancel-safe task execution
- Password prompt for encrypted archives
- Platform-native packaging (AppImage, .dmg, .msi)
See docs/GUI_MVP_PLAN.md for detailed planning and task breakdown.
Phase 3 (Future)
- Platform-native installers (Homebrew, winget, APT)
- Additional format support (as needed)
Configuration
GeeZipX follows the XDG Base Directory Specification for config files. At present, all configuration is done through command-line flags; no config file is needed.
Contributing
Contributions are welcome! Please read AGENTS.md for development conventions and collaboration guidelines.
Before submitting a PR:
- Ensure all tests pass:
cargo test --workspace --all-features - Run clippy with no warnings:
cargo clippy --workspace --all-targets --all-features -- -D warnings - Check formatting:
cargo fmt --all --check - Update documentation if your change affects the public API or CLI behavior
License
This project is licensed under the MIT License -- see LICENSE for details.