Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save arnoschutijzer/196a45d4b00a4a479ecc837dc57f4247 to your computer and use it in GitHub Desktop.
Save arnoschutijzer/196a45d4b00a4a479ecc837dc57f4247 to your computer and use it in GitHub Desktop.
  1. download & install youtube-dl (https://github.com/rg3/youtube-dl/blob/master/README.md#readme) (for mac: brew install libav & brew install youtube-dl)
  2. add the following function to your shell env:
ytdl() {
  youtube-dl -x --audio-format=mp3 --no-playlist -o "$1.%(ext)s" $2
}
  1. use it like so: ytdl "Hello - World" http://link.to/youtube-vid (playlist can be appended, it will be ignored)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment