This commit is contained in:
simono41 2017-09-23 17:10:53 +02:00
parent ff5f8259e1
commit 7febc2bb08
2 changed files with 11 additions and 5 deletions

View file

@ -41,4 +41,4 @@ fi
mkdir -p $pfad mkdir -p $pfad
cd $pfad cd $pfad
youtube-dl -i --socket-timeout 10000 $format $url youtube-dl -i --socket-timeout 10000 --force-ipv4 $format $url

View file

@ -16,25 +16,31 @@ then
voll="-fs" voll="-fs"
fi fi
read -p "Soll ein Video heruntergeladen werden oder Audio? [opus/audio/video/BEST/4k] : " format read -p "Soll ein Video heruntergeladen werden oder Audio? [opus/m4a/video/hd/fullhd/4k] : " format
if [ "$format" == "opus" ] if [ "$format" == "opus" ]
then then
format="-f 251" format="-f 251"
elif [ "$format" == "audio" ] elif [ "$format" == "m4a" ]
then then
format="-f 140" format="-f 140"
elif [ "$format" == "video" ] elif [ "$format" == "video" ]
then then
format="-f 43" format="-f 43"
elif [ "$format" == "4k" ] elif [ "$format" == "hd" ]
then
format="-f 247+251"
elif [ "$format" == "fullhd" ]
then then
format="-f 303+251" format="-f 303+251"
elif [ "$format" == "4k" ]
then
format="-f 315+251"
fi fi
if [ "$suche" == "suche" ] if [ "$suche" == "suche" ]
then then
youtube-dl "ytsearch:$wort" -q $format -o- | mplayer $voll -cache 8192 - youtube-dl "ytsearch:$wort" -q $format -o- | mplayer $voll -cache 8192 -
else else
youtube-dl -q $format -o- $url | mplayer $voll -cache 8192 - youtube-dl -q --force-ipv4 $format -o- $url | mplayer $voll -cache 8192 -
fi fi