I needed to download a 3k+ playlist from youtube. It pissed me off how often the music would get deleted from there and the ads…

The best tool for the job was YT-DLP.

https://github.com/yt-dlp/yt-dlp?tab=readme-ov-file#installation

Shit ton of options and always working. With linux it comes bundled with GUI automatically so… yeah. Another reason to change from windows to linux.

Thanks to having a GUI to work with, I had more time to work on the settings I wanted on the music. Here are the settings I used:

-f bestaudio --extract-audio --audio-quality 0 --embed-thumbnail --audio-format opus --embed-metadata --yes-playlist --lazy-playlist --embed-chapters --continue --no-overwrites --ignore-errors --compat-options no-live-chat --download-archive My_mix.txt

This “script” will try to download the playlist presented, do so one by one and make a record into My_mix.txt file. So if your power goes out, you can resume, where you stopped. Also it will embed chapters into the file, description and other things.

–ignore-config -o %(uploader)s-%(title).60s-%(id)s.%(ext)s

This part here just outputs a file name with an uploader-video_title-yt_id.extension(.opus)

I also made 2 scripts for downloading videos. One where you download it in best quality possible: -f bv*+ba/b --embed-subs --embed-metadata --embed-thumbnail --yes-playlist --lazy-playlist --embed-chapters --continue --no-overwrites --ignore-errors --compat-options no-live-chat --download-archive archive_list.txt --xattrs

And other where if you want to archive a channel you don’t need to necessarily the best quality (4K) video for an essay. 1080p or smaller, I found was enough:

-f bestvideo[height<=1080][ext=mkv][vcodec^=avc]+bestaudio[ext=opus]/bestvideo[height<=1080]+bestaudio --embed-subs --embed-metadata --embed-thumbnail --yes-playlist --lazy-playlist --embed-chapters --continue --no-overwrites --ignore-errors --compat-options no-live-chat --download-archive archive_list.txt --xattrs

You might want to change some settings here. That’s why you should do several test runs on smaller playlists and tweak them however you like. You will also need a VPN for huge playlists, because you will get throttled by ISP (internet service provider) or Youtube.

I recommend Mullvad VPN:

https://mullvad.net/de

Yeah !! SLSK, nicotine+ is the best way to get your music. Can’t believe it exists for so long an only heard about it here on lemmy 2 years ago.

However, YT-DLP has it own merit with youtube ! There are some great YouTuber’s out there doing some very good journalism, science and other stuff ! And archiving them with tubearchivist, tubesync or pinchflat is the best we can get anyway !

nicotine+

Ooh didn’t know about it, thanks!

Create a post

This is the official technology community of Lemmy.ml for all news related to creation and use of technology, and to facilitate civil, meaningful discussion around it.


Ask in DM before posting product reviews or ads. All such posts otherwise are subject to removal.


Rules:

1: All Lemmy rules apply

2: Do not post low effort posts

3: NEVER post naziped*gore stuff

4: Always post article URLs or their archived version URLs as sources, NOT screenshots. Help the blind users.

5: personal rants of Big Tech CEOs like Elon Musk are unwelcome (does not include posts about their companies affecting wide range of people)

6: no advertisement posts unless verified as legitimate and non-exploitative/non-consumerist

7: crypto related posts, unless essential, are disallowed

  • 1 user online
  • 35 users / day
  • 193 users / week
  • 387 users / month
  • 1.41K users / 6 months
  • 1 subscriber
  • 4.62K Posts
  • 51K Comments
  • Modlog