下载你最喜欢的YouTube视频
Download your favourite YouTube videos

原始链接: https://criminallyvulgar.dev/you-should-absolutely-download-your-favourite-youtube-videos/

转达Laura的建议:下载并归档你关心的网络媒体,因为平台会删除或限制内容。yt-dlp等基础工具让这很容易。作者的过度配置服务于睡眠习惯:通过Jellyfin NAS库在电视上观看Many a True Nerd的Let's Plays。Jellyfin僵硬的剧集结构需要ytdl-sub的YAML配置来保留播放列表;大多数频道需要的结构更少。一个怪癖导致Jellyfin会重复列出播放列表视频,除非将播放列表标题用作季号,但修复已有导入需要完全重新导入。存储方面,Tdarr将库重新编码为HEVC/H.265,在2TB上节省约700GB,但其界面复杂,不广泛推荐。总体信息:占有并归档对你重要的内容。

Hacker News 的讨论围绕一篇博客文章,内容是使用 yt-dlp 和 Jellyfin 归档喜爱的 YouTube 视频。用户描述了 YouTube 普遍存在的链接失效、视频被移除或隐藏以及旧内容丢失的问题。许多人推荐使用 yt-dlp、Tube Archivist、Youtarr、Invidious、Freetube、Podsync 以及基于 RSS 的脚本等工具备份视频。评论者就存储需求、画质取舍以及囤积是否值得展开辩论。其他人指出分享存档内容的法律障碍和版权限制,同时建议 Internet Archive 或点对点网络作为可能的保存途径。有些人主张让内容自然消失;另一些人则强调保存历史和个人喜爱的内容。实用技巧包括避免使用主账号、延后下载、处理文件名以及使用播放列表。总体而言,该讨论串强调 YouTube 长期访问并不可靠,因此个人归档日益必要,但伴随着技术、法律和伦理上的权衡。
相关文章

原文

Signal boosting Laura's post that you should absolutely download and archive the stuff that matters to you. The corporate internet is hostile to art and the things you love do not belong to you unless you claim them for yourself. If you've been around for a while on YouTube, just look at your "liked videos" playlist and see how many of the early ones are no longer available (something you literally have to enable in the playlist settings, it's that endemic).

The tools to do this in a basic way are extremely easy to get hold of, and generally have good defaults. I'm also going to talk a little about my own setup, and why it is the weird way it is, but it's definitely overkill for most setups. yt-dlp or one of it's many wrappers will do most of what you need, and a folder on a bulk storage drive or NAS will be plenty sufficient to make sure you always have access to them.

For me though, I had a particular need - I have unfortunately programmed myself to be almost entirely unable to fall asleep without a Many a True Nerd Let's Play on a low volume.

This comes with a couple of issues.

  1. I need to be able to play it on my TV.
  2. It has to integrate into my existing NAS infrastructure.
  3. I need to be able to organise hundreds of videos across dozens of playlists. This is a bigger sticking point than it sounds.
  4. Adding new ones or placing them can't be a manual job. Again, hundreds of videos.

My NAS media library is built around Jellyfin, which has a concept of Playlists but they're really not intended as a first-order organisational structure. You're expected to take a few tracks from a bunch of existing albums and place them in a playlist separate from the actual Library. No, Jellyfin has a very rigid concept of either Movies, TV Shows > Seasons > Episodes, or Artists > Albums > Songs.

TV Shows is the obvious analogue here, and with some really wild finagling I was able to get a setup together that is good enough to satisfy for now. My setup looks like this:

In Jellyfin I have a Library setup in TV Shows mode called YouTube. I've turned off all metadata scrapers and the like, and have it set to prefer file data over file names.

This is the only yt-dlp wrapper that allowed me to properly maintain the Playlist structure to any extent, and is entirely based on a series of .yaml files. In it's self-hosted docker-compose form, it comes with a web-app VSCode IDE which is honestly super handy - bridges the tech-comfort gap nicely.

I have a custom genre and list of MATN playlists I want it to collect and set metadata for. My list of playlists and videos

You can also see there I have a handful of Folding Ideas videos set as "Documentaries" - this is more in keeping with how ytdl-sub expects to be used.

The truth is that 99% of youtubers, and 99.9% of viewers, don't particularly need to structure everything as playlists within a channel. Most have a much higher proportion of one-off to series videos that make my MATN structure utterly pointless. As such, ytdl-sub defaults to tagging videos with a Season field organised by Year, but it stores them in folders named for the Playlist. This leads to Jellyfin putting every one of those playlist videos in 2 places within the channel - a Year Series, and a Playlist Series:My MATN Jellyfin Page

I only recently realised how to fix this, which is to assign the Playlist title as the Season Number in my ytdl-sub config file - it seems like it should break, but it doesn't: my config file in ytdl-sub

I could write a script to go in and fix this for all my existing series, but the issue is that once Jellyfin has Imported a video, I can't get it to update the Season Number without fully reimporting the Library, something I'm not really interested in doing for a terabyte of video. Oh, speaking of storage size...

Tdarr is a service that can automatically run through a library of videos and re-encode it in whatever way you desire - usually to some smaller, more efficient format or codec. I use it to encode everything in my media server to HEVC/H.265 as storage is my main bottleneck - processing power is the tradeoff and I have that in spades.

I'm honestly not going to recommend Tdarr unless you are very comfortable looking at a massively complex and poorly designed UI and making the smart decision to do the minimum. Everyone I know who has used it has come in with grand ambitions of brilliant complex workflows and settled on just using the default one because it works fine.

It has a tendency to break on anything remotely complex, and I had to manually tweak a script so that it wouldn't cry any time there was a data stream, but once it gets going it just chugs along re-encoding gigabyte after gigabyte.

It does seem to cause Jellyfin to lose Thumbnail images for reasons I haven't fully figured out, but it's generally fixable either manually, with a "refresh metadata", or in your media management software of choice.

It saved me about 700GB across my 2TB library, though I probably could have avoided some of that cost by just being more picky about my downloads.

Again, I don't really recommend it! But if you're in a pinch, it will absolutely do the job.


✉️ Reply via email

#blog #homelab

联系我们 contact @ memedata.com