From 850402e5528fbe67ec532a8158395bea315adcae Mon Sep 17 00:00:00 2001 From: trivernis Date: Fri, 29 Dec 2023 22:35:55 +0100 Subject: [PATCH] Fix ytdl scripts to have a proper fallback --- dot_local/share/scripts/ytdl.nu | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/dot_local/share/scripts/ytdl.nu b/dot_local/share/scripts/ytdl.nu index 340ff69..421e863 100644 --- a/dot_local/share/scripts/ytdl.nu +++ b/dot_local/share/scripts/ytdl.nu @@ -1,3 +1,8 @@ + export def `ytdl playlist` [url: string] { - yt-dlp --yes-playlist -N 8 --playlist-reverse --embed-metadata --sponsorblock-mark sponsor -f "bv[height=1080][vcodec~='av01\\..*']+ba / b[height=1080]" -o "%(uploader)s - %(title)s - %(id)s.%(ext)s" $url + yt-dlp --yes-playlist -N 8 --playlist-reverse --embed-metadata --sponsorblock-mark sponsor -f "bv[vcodec~='av01\\..*']+ba / bv+ba" -o "%(uploader)s - %(title)s - %(id)s.%(ext)s" $url +} + +export def `ytdl playlist 1080p` [url: string] { + yt-dlp --yes-playlist -N 8 --playlist-reverse --embed-metadata --sponsorblock-mark sponsor -f "bv[height=1080][vcodec~='av01\\..*']+ba / bv[height=1080]+ba" -o "%(uploader)s - %(title)s - %(id)s.%(ext)s" $url }