EZFT (Easy File Transfer) is a high-performance file transfer tool written in Go that supports both client download and server functionality. It features concurrent downloads, resume capability, progress tracking, and efficient file serving.
- High-Performance Concurrent Downloads: Multi-threaded downloading with configurable concurrency
- Resume Download Support: Automatic resume from interruption points
- Progress Tracking: Real-time download progress display with visual progress bar
- Auto Chunking: Intelligent chunk size calculation for optimal performance
- Retry Mechanism: Configurable retry count for failed downloads
- Range Request Support: Efficient partial content downloads
- Signal Handling: Graceful interruption handling (Ctrl+C)
- High-Performance File Server: Efficient HTTP-based file serving
- Range Request Support: Partial content delivery for resume downloads
- Multi-Client Support: Concurrent client handling
- Logging Middleware: Request logging and monitoring
- Directory Management: Automatic directory creation and management
git clone https://github.com/easzlab/ezft.git
cd ezft
go build -o build/ezft cmd/main.go
go install github.com/easzlab/ezft@latest
Start a file server to serve files from a directory:
# Start server on default port 8080 serving current directory
./ezft server
# Start server on custom port serving specific directory
./ezft server --port 9000 --dir /path/to/files
# Short form
./ezft server -p 9000 -d /path/to/files
Server Options:
--port, -p
: Server port (default: 8080)--dir, -d
: Root directory to serve files from (default: current directory)
Download files with high performance and resume capability:
# Basic download
./ezft client --url http://example.com/file.zip
# Download with custom output path
./ezft client --url http://example.com/file.zip --output /path/to/save/file.zip
# High-performance concurrent download
./ezft client --url http://example.com/file.zip --concurrency 8 --chunk-size 2097152
# Download with custom settings
./ezft client \
--url http://example.com/file.zip \
--output downloads/file.zip \
--concurrency 4 \
--chunk-size 1048576 \
--retry 5 \
--progress
Client Options:
--url, -u
: Download URL (required)--output, -o
: Output file path (default: down/filename)--concurrency, -c
: Number of concurrent connections (default: 1)--chunk-size, -s
: Chunk size in bytes (default: 1048576 = 1MB)--retry, -r
: Retry count for failed downloads (default: 3)--resume
: Enable resume download (default: true)--auto-chunk
: Enable automatic chunk size calculation (default: true)--progress, -p
: Show download progress (default: true)
# Show version information
./ezft --version
# Show help
./ezft --help
./ezft client --help
./ezft server --help
# Start server serving files from /var/www/files on port 8080
./ezft server --dir /var/www/files --port 8080
# Download large file with 8 concurrent connections
./ezft client \
--url http://localhost:8080/largefile.iso \
--concurrency 8 \
--chunk-size 2097152 \
--output downloads/largefile.iso
# If download was interrupted, simply run the same command again
# EZFT will automatically detect and resume from the last position
./ezft client --url http://example.com/file.zip --output file.zip
- CLI Framework: Built with Cobra for robust command-line interface
- HTTP Client: Custom HTTP client with timeout and connection management
- Concurrent Downloads: Goroutine-based concurrent chunk downloading
- Resume Logic: JSON-based failed chunk tracking and recovery
- Progress Display: Real-time progress bar with speed calculation
- File Server: HTTP-based file server with Range request support
- Concurrent Downloads: Multiple goroutines download different chunks simultaneously
- Intelligent Chunking: Automatic chunk size calculation based on file size
- Connection Pooling: Efficient HTTP connection reuse
- Memory Efficient: Streaming downloads without loading entire files into memory
- Resume Capability: Failed chunk tracking and automatic recovery
- Go 1.24.4 or later
- Network connectivity for downloads
- Sufficient disk space for downloaded files
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -m 'Add some amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
If you encounter any issues or have questions, please open an issue on the GitHub repository.