Youtube - downloading a playlist - youtube-dl

后端 未结 7 1902
囚心锁ツ
囚心锁ツ 2021-01-29 17:31

I am trying to download all the videos from the playlist:

I am using youtube-dl for this and the command is:

youtube-dl -citk –format mp4 –yes-playlist          


        
相关标签:
7条回答
  • 2021-01-29 17:50

    I have tried everything above, but none could solve my problem. I fixed it by updating the old version of youtube-dl to download playlist. To update it

    sudo youtube-dl -U
    

    or

    youtube-dl -U
    

    after you have successfully updated using the above command

    youtube-dl -cit https://www.youtube.com/playlist?list=PLttJ4RON7sleuL8wDpxbKHbSJ7BH4vvCk
    
    0 讨论(0)
  • 2021-01-29 17:52

    The easiest thing to do is to create a file.txt file and pass the link url link so:

    https://www.youtube.com/watch?v=5Lj1BF0Kn8c&list=PL9YFoJnn53xyf9GNZrtiraspAIKc80s1i
    

    make sure to include the -a parameter in terminal:

    youtube-dl -a file.txt
    
    0 讨论(0)
  • 2021-01-29 17:54

    Removing the v=...& part from the url, and only keep the list=... part. The main problem being the special character &, interpreted by the shell.

    You can also quote your 'url' in your command.

    More information here (for instance) :

    https://askubuntu.com/questions/564567/how-to-download-playlist-from-youtube-dl

    0 讨论(0)
  • 2021-01-29 17:55

    Download YouTube playlist videos in separate directory indexed by video order in a playlist

    $ youtube-dl -o '%(playlist)s/%(playlist_index)s - %(title)s.%(ext)s'  https://www.youtube.com/playlist?list=PLwiyx1dc3P2JR9N8gQaQN_BCvlSlap7re
    

    Download all playlists of YouTube channel/user keeping each playlist in separate directory:

    $ youtube-dl -o '%(uploader)s/%(playlist)s/%(playlist_index)s - %(title)s.%(ext)s' https://www.youtube.com/user/TheLinuxFoundation/playlists
    

    Video Selection:

    youtube-dl is a command-line program to download videos from YouTube.com and a few more sites. It requires the Python interpreter, version 2.6, 2.7, or 3.2+, and it is not platform specific. It should work on your Unix box, on Windows or on macOS. It is released to the public domain, which means you can modify it, redistribute it or use it however you like.

    $ youtube-dl [OPTIONS] URL [URL...]
    
    --playlist-start NUMBER          Playlist video to start at (default is 1)
    
    --playlist-end NUMBER            Playlist video to end at (default is last)
    
    --playlist-items ITEM_SPEC       Playlist video items to download. Specify
                                     indices of the videos in the playlist
                                     separated by commas like: "--playlist-items
                                     1,2,5,8" if you want to download videos
                                     indexed 1, 2, 5, 8 in the playlist. You can
                                     specify range: "--playlist-items
                                     1-3,7,10-13", it will download the videos
                                     at index 1, 2, 3, 7, 10, 11, 12 and 13.
    0 讨论(0)
  • 2021-01-29 18:00

    Your link is not a playlist.

    A proper playlist URL looks like this:

    https://www.youtube.com/playlist?list=PLHSdFJ8BDqEyvUUzm6R0HxawSWniP2c9K
    

    Your URL is just the first video OF a certain playlist. It contains https://www.youtube.com/watch? instead of https://www.youtube.com/playlist?.

    Pick the playlist by clicking on the title of the playlist on the right side in the list of videos and use this URL.

    0 讨论(0)
  • 2021-01-29 18:09

    In a shell, & is a special character, advising the shell to start everything up to the & as a process in the background. To avoid this behavior, you can put the URL in quotes. See the youtube-dl FAQ for more information.

    Also beware of -citk. With the exception of -i, these options make little sense. See the youtube-dl FAQ for more information. Even -f mp4 looks very strange.

    So what you want is:

    youtube-dl -i -f mp4 --yes-playlist 'https://www.youtube.com/watch?v=7Vy8970q0Xc&list=PLwJ2VKmefmxpUJEGB1ff6yUZ5Zd7Gegn2'
    

    Alternatively, you can just use the playlist ID:

    youtube-dl -i PLwJ2VKmefmxpUJEGB1ff6yUZ5Zd7Gegn2
    
    0 讨论(0)
提交回复
热议问题