youtubedl用于获取视频标题和不下载视频的选项

2024-03-29 14:37:41 发布

您现在位置:Python中文网/ 问答频道 /正文

我想从视频列表中获取视频标题。

--flat-playlist选项返回视频id,我找不到返回视频标题的选项。你知道吗

youtube-dl --flat-playlist "https://app.pluralsight.com/library/courses/openid-and-oauth2-securing-angular-apps"
[pluralsight:course] openid-and-oauth2-securing-angular-apps: Downloading JSON metadata
[download] Downloading playlist: Securing Angular Apps with OpenID Connect and OAuth 2
[pluralsight:course] playlist Securing Angular Apps with OpenID Connect and OAuth 2: Collected 58 video ids (downloading 58 of them)
[download] Downloading video 1 of 58
[download] Downloading video 2 of 58
[download] Downloading video 3 of 58
...



--get-filename选项和--get-title选项,只打印第一个视频的名称,然后抛出ExtractorError('No video formats found')

youtube-dl --get-title "https://app.pluralsight.com/library/courses/openid-and-oauth2-securing-angular-apps" --verbose

Tags: appsandofget视频downloadvideo选项