A easiest, blazingly fast, parallel media compression tool for normal people
Installation • Usage • Examples • Configuration • Contributing
- 🚀 Blazingly Fast — Parallel & concurrent processing utilizing all CPU cores
- 🎬 Video Compression — H.265/HEVC, VP9, AV1 encoding with optimal settings
- 🖼️ Image Compression — WebP, AVIF, optimized JPEG/PNG output
- 🎵 Audio Compression — Opus, AAC, MP3 with configurable bitrates
- 📁 Batch Processing — Compress entire directories with one command
- 🔄 Recursive Mode — Process nested subdirectories
- 📊 Progress Display — Real-time progress bars and statistics
- ⚙️ Highly Configurable — Fine-tune quality, format, and performance
- 🛡️ Safe Defaults — Sensible presets that just work
No external FFmpeg installation required — Crunch includes embedded FFmpeg binaries!
Download the appropriate binary for your platform from the Releases page:
| Platform | File |
|---|---|
| macOS (Intel) | crunch-macos.zip |
| macOS (Apple Silicon) | crunch-macos.zip |
| Linux (x64) | crunch-linux.zip |
| Windows (x64) | crunch-windows.zip |
# Move the binary to a directory in your PATH
chmod +x crunch
sudo mv crunch /usr/local/bin/crunch
# Or add to your user bin directory
mkdir -p ~/.local/bin
mv crunch-* ~/.local/bin/crunch
chmod +x ~/.local/bin/crunch
# Add to PATH (add this line to ~/.bashrc or ~/.zshrc)
export PATH="$HOME/.local/bin:$PATH"- Create a directory for the binary, e.g.,
C:\Program Files\crunch\ - Move
crunch.exeto that directory and rename it tocrunch.exe - Add the directory to your system PATH:
- Open Settings → System → About → Advanced system settings
- Click Environment Variables
- Under System variables, find and select Path, then click Edit
- Click New and add
C:\Program Files\crunch\ - Click OK to save
crunch --version
crunch --help# Compress all media with default settings
crunch --default
# Compress only videos
crunch --videos
# Compress videos and images with specific formats
crunch --videos=mp4 --images=avif
# Specify compression directories
crunch --default --input=./media-folder/Usage: crunch [OPTIONS]
Options:
--default
Use default settings (videos=webm, images=webp)
-p, --path [<PATH>]
Path to process (default: current directory)
--level [<LEVEL>]
Compress leve
--prefix [<PREFIX>]
--videos [<VIDEOS>]
Video format. Use --videos for default(webm) or --videos=FORMAT
--images [<IMAGES>]
Image format. Use --images for default(webp) or --images=FORMAT
--audios [<AUDIOS>]
Audios format. Use --audios for default(webp) or --audios=FORMAT
-h, --help
Print help (see a summary with '-h')
-V, --version
Print version
EXAMPLES:
crunch --default Compress all media with default formats (video: webm, image: webp, audio: mp3)
crunch --videos Compress videos only (default: webm)
crunch --videos=webm Compress videos to webm
crunch --images=webp Compress images to webp
crunch --audio=mp3 Compress audios to mp3
SUPPORTED FORMATS:
Videos: webm, mp4, mkv, av1, etc.
Images: webp, avif, jpg, png, etc.
Audio: opus, mp3, aac, flac, etc.
# Compress all videos in current directory to WebM
crunch --videos
# Compress with maximum quality
crunch --videos --level=low
# Fast compression with lower quality
crunch --videos --level=high
# Full compression pipeline with custom settings
crunch \
--videos=mp4 \
--images=avif \
--audio=opus \┌─────────────────────────────────────────────────────────────┐
│ Crunch │
├──────────────┬──────────────┬──────────────┬────────────────┤
│ Scanner │ Scheduler │ Workers │ Reporter │
│ │ │ │ │
│ - Walk dirs │ - Job queue │ - FFmpeg │ - Progress │
│ - Filter │ - Priority │ - Parallel │ - Statistics │
│ - Classify │ - Balance │ - Async I/O │ - Errors │
└──────────────┴──────────────┴──────────────┴────────────────┘
│
▼
┌──────────────────┐
│ FFmpeg │
│ (subprocess) │
└──────────────────┘
Contributions are welcome! Please feel free to submit a Pull Request.
# Clone the repository
git clone https://github.com/yourname/crunch.git
cd crunch
# Install development dependencies
cargo build
# Run with debug output
RUST_LOG=debug cargo run -- --default
# Format code
cargo fmt
# Lint
cargo clippyWe use Conventional Commits:
feat: add AV1 encoding support
fix: handle spaces in filenames
docs: update installation instructions
perf: optimize parallel job scheduling
refactor: split video module
test: add compression quality tests
- GPU acceleration (NVENC, VideoToolbox)
- Watch mode (auto-compress new files)
- Web UI dashboard
- Cloud storage integration (S3, GCS)
- Custom FFmpeg preset files
This project is licensed under the MIT License - see the LICENSE file for details.
- FFmpeg — The powerhouse behind all media processing
- Rayon — Data parallelism library for Rust
- Clap — Command line argument parser
- Indicatif — Progress bar library
If you find Crunch useful, please consider giving it a ⭐
Made with 🦀 and ❤️