Skip to content

Instantly share code, notes, and snippets.

@TalalMash
Created August 2, 2024 14:11
Show Gist options
  • Save TalalMash/b8d27da2eb3c4eee8e95b67d721bbc57 to your computer and use it in GitHub Desktop.
Save TalalMash/b8d27da2eb3c4eee8e95b67d721bbc57 to your computer and use it in GitHub Desktop.
yt-dlp archiver with resolution limit, thumbnail and metadata embeds
#!/bin/sh
# Use to throttle without cookies
# --sleep-interval 17 \
# --max-sleep-interval 135 \
QUALITY="bestvideo[height<=720]+bestaudio"
URL="URLHERE/videos"
ARCHIVE_LIST="archive.txt"
LOG=log.txt
COOKIES=cookies.txt
/usr/local/bin/yt-dlp \
--cookies ${COOKIES} \
--download-archive ${ARCHIVE_LIST} \
--embed-metadata \
--embed-subs \
--buffer-size 2048K \
--no-call-home \
--merge-output-format mp4 \
--format ${QUALITY} \
-ciw --restrict-filenames \
--convert-thumbnails jpg \
--embed-thumbnail \
-o "thumbnail:%(title)s.%(ext)s" \
-o "%(title)s.%(ext)s" \
-v ${URL} > ${LOG}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment