获取Youtube频道所有video的观看链接

Youtubevideo可以单独观看,也可以是播放列表的一部分。
例:
https://www.youtube.com/watch?v=vbsNiOkm0BU和
https://www.youtube.com/watch?v=vbsNiOkm0BU&index=141&list=UUmM7KPLEthAXiPVAgBF6rhA

注意部分vbsNiOkm0BU

问题是为频道/播放列表的所有video获取此部分。

动机是下载此频道的所有video(约3600)。 但我没有成功使用youtube-dl下载。
所以我希望以一堆100个的forms下载它,作为一个例子。

如果我可以进一步提出这个问题,我可以编写一个bash脚本来仅下载播放列表的特定索引吗?

如果您看到以上链接:
https://www.youtube.com/watch?v=vbsNiOkm0BU&index=141&list=UUmM7KPLEthAXiPVAgBF6rhA
注意part &index=141

现在,如果做这样的事情:

 for i in {100..200} do youtube-dl https://www.youtube.com/watch?v=vbsNiOkm0BU&index=${i}&list=UUmM7KPLEthAXiPVAgBF6rhA done 

注意part &index=${i}

由于vbsNiOkm0BU ,这是一次又一次地下载相同的video。

任何有关这方面的帮助将不胜感激。 谢谢。

播放列表

 youtube-dl -f FORMAT -cit --playlist-start NUMBER-START --playlist-end NUMBER-END  

…其中被替换为播放列表的URL,将FORMAT替换为任何可用的video格式,例如18NUMBER-START是首先开始下载的播放列表中的video编号,以及NUMBER-START是最后下载的播放列表中的video编号。

渠道

如果某个频道有多个播放列表,请单击第一个播放列表,然后使用上述命令下载所选播放列表中的所有video。 然后对频道中的每个播放列表重复。

说明

 -f, --format FORMAT video format code. The -F option (capital F) displays all available video formats for a video link. Example: youtube-dl -F  -c, --continue force resume of partially downloaded files -i, --ignore-errors continue on download errors, for example to skip unavailable videos in a channel -t, --title use title in file name (default) 

将所有video节目转换为小写

 youtube-dl -f FORMAT -ci --output '%(title)s.%(ext)s' --playlist-start NUMBER-START --playlist-end NUMBER-END  find -type f -exec rename 'y/AZ/az/' {} + 

说明

 --output '%(title)s.%(ext)s' output file name(s) as the name of the video, followed by a dot character and the video's extension find -type f Find all files. y/source/destination/ Transliterate the characters in the pattern space which appear in source to the corresponding character in destination.