Skip to content

Commit

Permalink
Fix: yt-dlp still use android as default player
Browse files Browse the repository at this point in the history
Force yt-dlp use web as default player so it can get metadata and playable
  • Loading branch information
herowinb committed Mar 31, 2024
1 parent ff336e9 commit 67528bc
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion live-dl
Original file line number Diff line number Diff line change
Expand Up @@ -730,7 +730,7 @@ function func_check_state() {
__info "using address: ${_youtube_dl_address_param##* }"
fi
METADATA=`yt-dlp --ignore-config --no-playlist --playlist-items 0 --cookies "$COOKIES_FILE" \
--skip-download --print-json --referer 'https://www.youtube.com/feed/subscriptions' \
--skip-download --print-json --extractor-args "youtube:player_client=web" --referer 'https://www.youtube.com/feed/subscriptions' \
-o '%(upload_date)s %(title)s (%(id)s).%(ext)s' \
${_youtube_dl_address_param} \
"$_url" 2>&1`
Expand Down Expand Up @@ -1551,6 +1551,7 @@ function func_download_youtube() {
--fragment-retries 30 \
--retries 30 \
--live-from-start \
--extractor-args "youtube:player_client=web" \
$FORTMAT_OPTION \
--cookies "$COOKIES_FILE" \
-o "${OUTPUT_PATH}${EXTENSION}" \
Expand All @@ -1577,6 +1578,7 @@ function func_download_youtube() {
--add-metadata \
--external-downloader aria2c \
--external-downloader-args '-j 16 --retry-wait 10 --max-tries 10' \
--extractor-args "youtube:player_client=web" \
-f "$FORTMAT_OPTION" \
--retries 30 \
--cookies "$COOKIES_FILE" \
Expand All @@ -1588,6 +1590,7 @@ function func_download_youtube() {
--ignore-config \
--external-downloader aria2c \
--external-downloader-args '-j 16 --retry-wait 10 --max-tries 10' \
--extractor-args "youtube:player_client=web" \
-f "$FORTMAT_OPTION" \
--retries 30 \
--cookies "$COOKIES_FILE" \
Expand Down

0 comments on commit 67528bc

Please sign in to comment.