Skip to content

Instantly share code, notes, and snippets.

@bafflingscience
Last active April 7, 2020 20:07
Show Gist options
  • Save bafflingscience/c6c2a1e3b29da5ec1b073e98dfd3a716 to your computer and use it in GitHub Desktop.
Save bafflingscience/c6c2a1e3b29da5ec1b073e98dfd3a716 to your computer and use it in GitHub Desktop.
youtube-dl - download playlist, output to existing directory, create directory, output files to new directory, index playlist videos.
#! /bin/bash
ytdl() {
/usr/local/bin/youtube-dl \
--verbose \
--playlist-start 1 \
--download-archive /Users/user/Archive/playlist_archive.txt \
--add-metadata \
--embed-thumbnail \
--write-description \
--xattrs \
--cookies /Users/user/Archive/cookies.txt \
-i \
-o "/Volumes/fourtb/Video/Playlists/%(playlist_title)s/%(playlist_index)s - %(title)s.%(ext)s" \
-f "mp4" \
$1
}
ytdl $1
echo "Great job Dave!"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment