Compare commits

..

No commits in common. "28395cd5e8cc43645c2c11b39e6fc9c2b3413614" and "76b633cbdb055608871943273c951251b8eb4258" have entirely different histories.

9
yt
View File

@ -19,7 +19,6 @@
set -e
test -z "$DEBUG" || set -x
test -z "$XDG_CACHE_HOME" && cachefile="$HOME/.cache/yt.cache" \
|| cachefile="$XDG_CACHE_HOME/yt.cache"
@ -89,9 +88,7 @@ cache() { # cache the video title for faster retrieval
clone() { # clones a YouTube playlist to a file
test -d "$YT_PL_DIR" || mkdir -p "$YT_PL_DIR"
if test -n "$2" && file="$2" \
|| file="$YT_PL_DIR/$('%(playlist)s' "$1").m3u"
file="$YT_PL_DIR/$2.m3u"
yt-dlp --flat-playlist "$1" --print url > "$file"
verify "$file"
@ -290,7 +287,7 @@ case "$com" in
cache "$@"
;;
clone)
shift 2>/dev/null || usage 'clone uri [file]'
shift 2>/dev/null || usage 'clone uri file'
clone "$@"
;;
list)
@ -314,7 +311,7 @@ case "$com" in
queue "$@"
;;
search)
shift 2>/dev/null || usage 'search term [count]'
shift 2>/dev/null || usage 'search term count'
search "$@"
;;
verify)