Skip to content

Instantly share code, notes, and snippets.

@xDShot
Created June 14, 2024 20:31
Show Gist options
  • Save xDShot/370beed3a5f25568e016da6310c1c06b to your computer and use it in GitHub Desktop.
Save xDShot/370beed3a5f25568e016da6310c1c06b to your computer and use it in GitHub Desktop.
yt-dlp templates
# Yandex
export YA_ALBUM="Albums/%(artist)s/%(album)s (%(release_year)s)/%(track_number)02d %(artist)s - %(track)s-%(id)s.%(ext)s"
export YA_TRACK="%(artist)s - %(track)s-%(id)s.%(ext)s"
function YA_dl () {
yt-dlp --cookies-from-browser chrome -o "$1" --restrict-filenames $2
}
function YA_album_dl () {
YA_dl "$YA_ALBUM" $1
}
# Youtube Music
function YTM_dl () {
yt-dlp -x --cookies-from-browser chrome -o "$1" --restrict-filenames $2
}
function YTM_album_dl () {
YTM_dl "$YA_ALBUM" $1
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment