Skip to content

MarcoTomasRodriguez/hget

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

60 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Logo

hget

Interruptible and resumable download accelerator.
Explore the docs »

View Demo · Report Bug · Request Feature

Description

hget is a command-line tool written in Go that downloads files at maximum speed by using range downloads with multiple workers and shines when the bottleneck is on the server.

It takes advantage of the Range header, allowing many workers to download in parallel a file. That said, it is not a Swiss Army Knife: if there is no bottleneck in the server, it is probably better to use just 1 download worker; else, you should set the number of workers to the minimum value that allows you to download at the maximum of your internet speed.

For example, if the client can download 100MB/s and the server only provides you 10MB/s per worker, then it would be wise to use ~10 download workers (beware of context switching). Nevertheless, if the client has 10MB/s and the server provides you >10MB/s, there is no need to use more than 1.

Additional features

  • Interruptible downloads: press Ctrl + C or + C and the download will stop gracefully.
  • Resumable downloads: use hget resume ID to resume an interrupted download.

(back to top)

Installation

Using Go

go install github.com/MarcoTomasRodriguez/hget@latest

Binary

Precompiled binaries for Linux and MacOS are available at https://github.com/MarcoTomasRodriguez/hget/releases.

(back to top)

Usage

Download

hget [-n workers] URL

-n Download workers (Default: CPUs).

Download demo

List

hget list

Resume

hget resume <ID>

Remove

hget remove <ID>

Clear

hget clear

(back to top)

Acknowledgments

  • huydx for creating the initial version of this project.

(back to top)

License

Distributed under the MIT License. See LICENSE.txt for more information.

(back to top)