General Introduction
Lux is a fast and simple video download library and command line tool written in Go. It supports downloading videos from multiple websites, including YouTube, Bilibili, Youku, etc. Lux provides a variety of download options and features, such as multi-threaded downloads, breakpoints, automatic retries, etc., which greatly improves the download efficiency and user experience. lux also supports downloading through proxies, authentication with cookies, and other advanced features, which is suitable for a variety of download needs.
This project is shared to quickly integrate your AI workflow with as many video platform download capabilities as possible.
Function List
- Multi-platform support: Supports multiple operating systems such as Windows, macOS, Linux, and more.
- Multi-threaded downloads: Increase download speed and save time.
- stop-and-go (computing): Downloading can be continued after interruption to avoid repeated downloads.
- auto-retry: Automatically retry when the download fails to ensure a successful download.
- Agent Support: Download via proxy server to protect privacy.
- Cookies Support: Authentication using cookies to download videos that require login.
- Multiple format support: Supports a wide range of video formats and quality options.
- command-line operation: Simple and efficient operation through a command line interface.
Using Help
Installation process
- Installation via Go::
go install github.com/iawia002/lux@latest
- Installation via Homebrew (macOS only)::
brew install lux
- Installation via Scoop (Windows)::
scoop install lux
- Installation via Chocolatey (Windows)::
choco install lux
Usage
- Download Video::
lux [OPTIONS] URL [URL...]
Example:
lux "https://www.youtube.com/watch?v=dQw4w9WgXcQ"
This command will download the video at the specified URL.
- View available video quality::
lux-i "https://www.youtube.com/watch?v=dQw4w9WgXcQ"
This command will display all available video quality options.
- Specify download format::
lux-f 248 "https://www.youtube.com/watch?v=dQw4w9WgXcQ"
This command will download the video in the specified format.
- stop-and-go (computing)::
lux-c "https://www.youtube.com/watch?v=dQw4w9WgXcQ"
This command will continue the last incomplete download.
- Using a proxy to download::
lux --proxy http://proxyserver:port "https://www.youtube.com/watch?v=dQw4w9WgXcQ"
This command will download the video through the specified proxy server.
- Downloading with Cookies::
lux --cookie "cookie_string" "https://www.youtube.com/watch?v=dQw4w9WgXcQ"
This command will authenticate and download the video using the specified cookies.
Advanced Features
- Multi-threaded downloads: By
--threads
option specifies the number of download threads. - auto-retry: By
--retry
option sets the number of retries when the download fails. - Specify the output path and file name: By
-o
option specifies the path and filename to save the downloaded file. - debug mode: By
--debug
option enables debug mode and outputs detailed debugging information.