#!/bin/bash
source ~/ImporTiVo_Settings.sh


if [ -f config/stop.processing ]
then
	echo "Aborting: stop.processing file found in config directory"
	exit 0
else
	
	
	
	
if [ -f DownloadList.inprogress ]
then
	echo Aborting: DownloadList is running...
	exit 0
fi

touch DownloadList.inprogress
rm -f ./queue/download.sh
./buildDownloadScripts
./buildQueue download
./queue/download.sh


rm -f DownloadList.inprogress

fi
