Yt-dlp is the gold standard for that.
https://github.com/yt-dlp/yt-dlp
Tag cleanup and album art are their own beast that you’ll wanna tackle post-download, but beets is another gold standard tool that can help with that layer.
If you prefer Rust, yaydl (disclosure: I wrote it) would be an alternative to yt-dlp. (Patches welcome - right now, I much depend on Invidious to get YouTube contents.)
+1 for Beets - awesome software!
Yeah I am using yt-dlp to download the music, and I can set that on a cronjob no problem.
I am specifically asking for better downloading (I don't want just the raw YouTube title most of the time), album art, and ID3 tagging. But that beets.io thing looks super cool! I might integrate that into my existing python scripting instead of trying to build it all out myself
Just to throw out an easy option: if the music is well-labeled on Youtube, you can get pretty close to that full suite with just yt-dlp by using --embed-thumbnail
as a stand-in for album art, dumping your files with an “Artist - track - album” naming structure using the --output-template
flag — then using an awk or python script as a second pass to add the artist/track/album names to each file as tags.
E: and in case it isn’t self-evident, you don’t have to give yt-dlp a URL for each track; it’ll work fine with a playlist URL.
Haha unfortunately the music on YouTube is not especially well managed. Ive been using YouTube for music for a long time so a lot of my music is uploaded by Vevo or "{Artist} - Topic" and stuff like that. Plus (IIRC) YouTube music doesn't give things like what album a song is from or when it was released
Download with yt-dlp. All of it. Even into a single folder if that's easier.
Then run it all through Picard and that'll do everything else for you - albumart, metadata, folders, filenames, the lot.
Anything that Picard doesn't know about, enter it into the MusicBrainz db to give back to the community.
Done.
Every single tool that downloads from YouTube is just a yt-dlp wrapper 😀
JDownloader is the best for downloading anything from YouTube. It may also support YouTube Music
Selfhosted
A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.
Rules:
-
Be civil: we're here to support and learn from one another. Insults won't be tolerated. Flame wars are frowned upon.
-
No spam posting.
-
Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it's not obvious why your post topic revolves around selfhosting, please include details to make it clear.
-
Don't duplicate the full text of your blog or github here. Just post the link for folks to click.
-
Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).
-
No trolling.
Resources:
- selfh.st Newsletter and index of selfhosted software and apps
- awesome-selfhosted software
- awesome-sysadmin resources
- Self-Hosted Podcast from Jupiter Broadcasting
Any issues on the community? Report it using the report flag.
Questions? DM the mods!