4 ms·
I like this command to extract audio from youtube videos: youtube-dl --extract-audio --audio-format mp3 <url>
by awqrre 11y ago
I like this command to extract audio from youtube videos:
youtube-dl --extract-audio --audio-format mp3 <url>
- DarkLinkXXXX 11y agoOr you could use -x, which would only download the audio (because there's seperate audio and video streams on youtube).
- awqrre 11y agoyes -x is the same as --extract-audio, but I use an alias in my bashrc like this (if you don't use --audio-format mp3, you might not get mp3 (not necessarily a bad thing)): alias youtubemp3='youtube-dl --extract-audio --audio-format mp3'
- melicerte 11y agoThat's my main use of youtube-dl for years now. I'm extracting audio from old french movies available on youtube, work a small sound extract with audacity and then post the result on soudcloud[1]. [1] A bit of self-promotion here, if you are interested this is my soundcloud playlist https://soundcloud.com/melicerte/sets/extraits-de-vieux-films https://soundcloud.com/melicerte/sets/extraits-de-vieux-film...
- wingerlang 11y agoWhy?
- luxpir 11y agoWhy not!
- wingerlang 11y agoI'm not against it or anything, I'm just wondering if it is a personal interest or if there is some niche usage I am unaware of.
- x0 11y agoThat is a really cool playlist.
- rg3 11y agoIf your music player supports OGG, you can also use youtube-dl -f FORMAT VIDEO_URL and give a numeric format that corresponds to a DASH webm audio-only stream, with vorbis audio (e.g. format 171 these days). The container is webm but it can be trivially changed to OGG with ffmpeg, which you can call via --exec automatically. Edit: I mentioned that because you don't lose any quality reencoding.
- otterpro 11y agoI like to keep it in original audio format (usually AAC) instead of mp3, because with mp3 conversion, there is also some loss of quality due to re-compression.