下载海豚传媒mp3脚本

2019-01-20  本文已影响0人  君淋天下
#! /bin/bash
wget    http://media.dolphinmedia.cn/  
cat index.html | grep 'http://media.dolphinmedia.cn/album/'  | grep 'entry-title' | cut -d'"' -f4  > url_list.txt

total=`cat url_list.txt | wc -l`;
i=1;
for x in `cat url_list.txt`;
do
   echo "total task $total,current task is $i";
   let i++;
   echo $x;
   curl $x | grep mp3 | cut -d '"'  -f14 >> mp3_url_list.txt;
done

total=`cat mp3_url_list.txt | wc -l`;
i=1;
for x in `cat mp3_url_list.txt`;
do
   echo "total task $total,current task is $i";
   let i++;
   wget `echo $x | cut -d "?" -f1`   -P mp3/;
done 
上一篇下一篇

猜你喜欢

热点阅读