Skip to content
9 changes: 6 additions & 3 deletions ani-cli
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh

version_number="4.10.6"
version_number="4.10.7"

# UI

Expand Down Expand Up @@ -299,8 +299,9 @@ download() {
# [ -e "$download_dir/$2.vtt" ] && ffmpeg -i "$download_dir/$2.mp4" -i "$download_dir/$2.vtt" -c copy -c:s mov_text "$download_dir/$2.bak.mp4" && mv "$download_dir/$2.bak.mp4" "$download_dir/$2.mp4"
;;
*)
command -v "yt-dlp" >/dev/null && yt-dlp --referer "$allanime_refr" -o "$download_dir/$2.mp4" "$1"
# shellcheck disable=SC2086
aria2c --referer="$allanime_refr" --enable-rpc=false --check-certificate=false --continue $iSH_DownFix --summary-interval=0 -x 16 -s 16 "$1" --dir="$download_dir" -o "$2.mp4" --download-result=hide
command -v "yt-dlp" >/dev/null || aria2c --referer="$allanime_refr" --enable-rpc=false --check-certificate=false --continue $iSH_DownFix --summary-interval=0 -x 16 -s 16 "$1" --dir="$download_dir" -o "$2.mp4" --download-result=hide
;;
esac
}
Expand Down Expand Up @@ -494,7 +495,9 @@ dep_ch "curl" "sed" "grep" || true
dep_ch "fzf" || true
case "$player_function" in
debug) ;;
download) dep_ch "ffmpeg" "aria2c" ;;
download)
command -v "yt-dlp" >/dev/null || echo "ffmpeg" "aria2c" | xargs -n1 command -v >/dev/null || die "Neither yt-dlp nor ffmpeg and aria2c found. Please install one."
;;
android*) printf "\33[2K\rChecking of players on Android is disabled\n" ;;
*iSH*) printf "\33[2K\rChecking of players on iOS is disabled\n" ;;
flatpak_mpv) true ;; # handled out of band in where_mpv
Expand Down