1、安装Python
官网:https://www.python.org/
下载地址:https://www.python.org/downloads/
当前版本:Python 3.13.5
2、使用pip安装you-get
pip install you-get# pip install --upgrade you-get
3、查看用法
~ # you-get
usage: you-get [OPTION]... URL...A tiny downloader that scrapes the weboptions:-V, --version Print version and exit-h, --help Print this help message and exitDry-run options:(no actual downloading)-i, --info Print extracted information-u, --url Print extracted information with URLs--json Print extracted URLs in JSON formatDownload options:-n, --no-merge Do not merge video parts--no-caption Do not download captions (subtitles, lyrics, danmaku, ...)--post, --postfix Postfix downloaded files with unique identifiers--pre, --prefix PREFIXPrefix downloaded files with string-f, --force Force overwriting existing files--skip-existing-file-size-checkSkip existing file without checking file size-F, --format STREAM_IDSet video format to STREAM_ID-O, --output-filename FILESet output filename-o, --output-dir DIR Set output directory-p, --player PLAYER Stream extracted URL to a PLAYER-c, --cookies COOKIES_FILELoad cookies.txt or cookies.sqlite-t, --timeout SECONDSSet socket timeout-d, --debug Show traceback and other debug info-I, --input-file FILERead non-playlist URLs from FILE-P, --password PASSWORDSet video visit password to PASSWORD-l, --playlist Prefer to download a playlist-a, --auto-rename Auto rename same name different files-k, --insecure ignore ssl errors-m, --m3u8 download video using an m3u8 urlPlaylist optional options:--first FIRST the first number--last LAST the last number--size, --page-size PAGE_SIZEthe page size numberProxy options:-x, --http-proxy HOST:PORTUse an HTTP proxy for downloading-y, --extractor-proxy HOST:PORTUse an HTTP proxy for extracting only--no-proxy Never use a proxy-s, --socks-proxy HOST:PORT or USERNAME:PASSWORD@HOST:PORTUse an SOCKS5 proxy for downloading
4、使用
4.1、查看信息
you-get -i 链接
4.2、下载
# 下载
you-get 链接# 下载:指定输出文件名
you-get -O 输出文件名 链接# 下载:指定输出目录
you-get -o 输出目录 链接
4.3、使用代理
# 使用代理下载(假设代理地址为127.0.0.1:8087)
you-get -x 127.0.0.1:8087 链接
5、支持下载的网站
详见:https://github.com/soimort/you-get#supported-sites
6、详见
https://you-get.org/
https://github.com/soimort/you-get
https://pypi.org/project/you-get/
https://mp.weixin.qq.com/s/t_0dT3-nsh0lSzv5jozyeQ