Skip to content

Instantly share code, notes, and snippets.

@mannprerak2
Created September 2, 2018 12:13
Show Gist options
  • Save mannprerak2/6626debc2d410d008cb1805176c25994 to your computer and use it in GitHub Desktop.
Save mannprerak2/6626debc2d410d008cb1805176c25994 to your computer and use it in GitHub Desktop.
Using Youtube-dl to download a playlist and converting it to mp3
youtube-dl -i --extract-audio --audio-format mp3 -o "%(title)s.%(ext)s" <url to playlist>
//replace diamond brackets < > with " " when pasting url
@mannprerak2
Copy link
Author

For downloading multiple playlists from urls from a file (urls separated by new lines)

cat playlist_links.txt | xargs -n1 youtube-dl -i --extract-audio --audio-format mp3 --add-metadata -o '%(playlist)s/%(playlist_index)s - %(track)s.%(ext)s'

See youtube-dl documentation here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment