youtube dl 神器介绍

警告
本文最后更新于 2020-03-12,文中内容可能已过时。

安装

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
## CentOS
sudo yum install epel-release
sudo rpm -v --import http://li.nux.ro/download/nux/RPM-GPG-KEY-nux.ro
sudo rpm -Uvh http://li.nux.ro/download/nux/dextop/el7/x86_64/nux-dextop-release-0-5.el7.nux.noarch.rpm

sudo yum -y install ffmpeg ffmpeg-devel

## ubuntu
sudo apt install ffmpeg

## 安装 youtube-dl
sudo apt install python3-pip
pip3 install youtube-dl   #安装
pip3 install --upgrade youtube-dl  #升级

## 或者使用 apt 安装
sudo apt-get install youtube-dl

使用

  • 设置代理
  • 设置下载功能
1
2
3
alias youdl='youtube-dl --yes-playlist  --playlist-start 1 --proxy "socks5://127.0.0.1:1086" --write-sub --sub-format "ass/srt/best" --convert-subs "srt"'

youdl https://www.youtube.com/watch?v=xVT1y0xWgww

效果

1
2
3
4
5
6
7
youdl https://www.youtube.com/watch?v=xVT1y0xWgww

[youtube] xVT1y0xWgww: Downloading webpage
[info] Writing video subtitles to: CppCon 2017 - Nir Friedman “What C++ developers should know about globals (and the linker)”-xVT1y0xWgww.en.vtt
WARNING: Requested formats are incompatible for merge and will be merged into mkv.
[download] Destination: CppCon 2017 - Nir Friedman “What C++ developers should know about globals (and the linker)”-xVT1y0xWgww.f248.webm
[download]  17.4% of 221.79MiB at 914.28KiB/s ETA 03:25

相关内容

william 支付宝支付宝
william 微信微信
0%