jb-templates/sh/coderradio.sh

36 lines
728 B
Bash
Raw Normal View History

2014-02-09 06:32:07 -06:00
# coderradio downloader
#HDvideo=""
MOBILEvideo="http://www.podtrac.com/pts/redirect.mp4/201402.jb-dl.cdn.scaleengine.net/coderradio/2014/cr-0087-432p.mp4"
MP3audio="http://www.podtrac.com/pts/redirect.mp3/traffic.libsyn.com/jbmirror/cr-0087-mp3.mp3"
OGGaudio="http://www.podtrac.com/pts/redirect.ogg/traffic.libsyn.com/jbmirror/cr-0087-ogg.ogg"
destDIR="/home/$USER/syncs/coderradio/"
function chkDIR(){
if [ ! -d ${destDIR} ];then
mkdir ${destDIR}
elif [ -d ${destDIR} ];then
main
fi
}
function main(){
rm -v -R ${destDIR}*.mp3
rm -v -R ${destDIR}*.ogg
rm -v -R ${destDIR}*.mp4
wget ${MOBILEvideo} -P ${destDIR}
wget ${MP3audio} -P ${destDIR}
wget ${OGGaudio} -P ${destDIR}
}
chkDIR