Skip to content

Instantly share code, notes, and snippets.

@saitodisse
Last active August 29, 2015 14:10
Show Gist options
  • Save saitodisse/8c6c138b79aa20830ee0 to your computer and use it in GitHub Desktop.
Save saitodisse/8c6c138b79aa20830ee0 to your computer and use it in GitHub Desktop.

Download only audio track

youtube-dl -f 141/140/139 --playlist-end 20 'https://www.youtube.com/user/videoscpflcultura/videos'

Convert m4a to mp3

for i in *.m4a; do avconv -i "${i}" -acodec libmp3lame "${i%.m4a}.mp3"; done

Extract audio from mp4 video

for i in *.mp4; do avconv -i "${i}" -map 0:1 -c:a copy "${i%.mp4}.aac"; done

Convert aac to mp3

for i in *.aac; do avconv -i "${i}" -acodec libmp3lame "${i%.aac}.mp3"; done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment