yt-dlp (youtube-dl) cmd

Ответить
ya
^-^
Сообщения: 2336
Зарегистрирован: 16 дек 2021, 19:56

yt-dlp (youtube-dl) cmd

Сообщение ya »

@echo off

d:
cd D:\video\

echo %cd%
set /p url="Enter Input url: "

yt-dlp -F "%url%"


::youtube-dl -f '137+140/bestvideo[height<=1080,ext=mp4]+bestaudio[ext=m4a]/best[height<=1080]' --cookies cookies-yt.txt --no-overwrites --continue "$url"


echo yt-dlp -f "bv*[height<=1080][ext=mp4]+ba*[ext=m4a][vcodec^=avc1]" --cookies cookies-yt.txt --no-overwrites --continue "%url%"

echo \n

::timeout /t 7


::yt-dlp -v -f "bv*[height<=1080][ext=mp4][vcodec^=avc1]+ba*[ext=m4a]" --cookies cookies-yt.txt --no-overwrites --continue "%url%"
yt-dlp -v -f "bv*[height<=1080][ext=mp4][vcodec^=avc1]+ba*[ext=m4a]" --no-overwrites --continue "%url%"


timeout /t 7
::@pause
ya
^-^
Сообщения: 2336
Зарегистрирован: 16 дек 2021, 19:56

Re: yt-dlp (youtube-dl) cmd

Сообщение ya »

Код: Выделить всё

#!/ usr/bin/env bash
# Download youtube video with desired quality

# youtube-dl accepts both fully qualified URLs and video id's such as AQcQgfvfF1M

url="$*"

echo "Fetching available formats for $url..."
youtube-dl -F "$url"
#read -p "Please enter the desired format id: " FORMAT

## download the video
#youtube-dl -f $FORMAT -g "$url"

youtube-dl -f '137+140/bestvideo[height<=1080,ext=mp4]+bestaudio[ext=m4a]/best[height<=1080]' --cookies cookies-yt.txt --no-overwrites --continue "$url"
#youtube-dl -f 'bestvideo[height<=1080,ext=mp4]+bestaudio[ext=m4a]' --cookies cookies-yt.txt --no-overwrites --continue --force-ipv4 --buffer-size 1M --http-chunk-size 5M "$url"
#youtube-dl -f '136+140' --cookies cookies-yt.txt --force-ipv4 --buffer-size 128K --http-chunk-size 1M "$url"


## stream the video with mpv (no local file created)
# mpv --cache=1024 $(youtube-dl -f $FORMAT -g "$url")
Ответить