Last active 1741649047

Revision 135fc3f9087d88c23399b4e41dad12f666039a30

download-youtube-videos.sh Raw
1#!/bin/bash
2path="/path/to/youtube"
3
4sudo chown -R airikr:airikr "${path}"
5
6yt-dlp \
7--check-formats \
8--progress \
9--ignore-errors \
10--download-archive "${path}/downloaded.txt" \
11--format "bv*[height<1080][ext=mp4]+ba" \
12--cookies-from-browser firefox:av9irb5a.edgren \
13--merge-output mkv \
14--write-info-json \
15--write-annotations \
16--write-thumbnail \
17--convert-thumbnails jpg \
18--add-metadata \
19--convert-thumbnail jpg \
20--embed-thumbnail \
21--embed-chapters \
22--embed-info-json \
23--restrict-filenames \
24--concurrent-fragments 3 \
25--sponsorblock-mark all,-preview,-filler,-interaction \
26--dateafter 20250201 \
27--playlist-end 10 \
28-a "${path}/channels.txt" \
29-o "${path}/%(channel)s/%(upload_date>%Y-%m-%d)s - %(title)s.%(ext)s"
30
31sudo chown -R jellyfin:jellyfin "${path}"