Created
November 6, 2018 14:46
-
-
Save hoangdh/dae677b2ce24918402e0897f0bf3b070 to your computer and use it in GitHub Desktop.
Tải film từ VTV Giải trí.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
regex='(https?|ftp|file)://[-A-Za-z0-9\+&@#/%?=~_|!:,.;]*[-A-Za-z0-9\+&@#/%=~_|]' | |
if [ -e $1 ] | |
then | |
lists=`cat $1` | |
for x in $lists | |
do | |
name=`echo $x | grep -Eo '?.*?\.mp4' | awk -F '/' {'print $NF'}` | |
ffmpeg -i "$x" -c copy $name | |
done | |
elif [[ $1 =~ $regex ]]; then | |
name=`echo $1 | grep -Eo '?.*?\.mp4' | awk -F '/' {'print $NF'}` | |
ffmpeg -i "$1" -c copy $name | |
else | |
echo 'Please insert input.' | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Bấm F12 > Chọn tab Network (Lọc file M3U8)
Lấy toàn bộ link M3U8 từ VTV Giải trí cho vào file text. Chạy script kèm theo file text
Yêu cầu: FFMpeg