How to make a MintCast Automatic Download

Write tutorials for Linux Mint here
More tutorials on ... /tutorials and (archive) on
Forum rules
Don't add support questions to tutorials; start your own topic in the appropriate sub-forum instead. Before you post read forum rules
Post Reply

How to make a MintCast Automatic Download

Post by anjanaya »

I've been using Mint for about an year now & there's no Question i love it.One one of my visits to the site i saw mintCast and was instantly attracted to it.
After downloading i very much liked the Style/Genuineness or something about it that hooked me to it.Ever since i visit the website to find the next mintCast.
Also while going through Linux Journal i saw the article about getting movie trivia from IMDB using a shell script.This got me thinking, Hmm. As i have download limit and free download only from 2 AM to 8 AM i thought why not download mintCasts using a shell Script?

Here's what i have put in cron to run at night.

Code: Select all


dnList=/tmp/$$.list	#location of mintCast URL's
trap "rm -f $dnList" EXIT

mintCastSite='';	# mintCast website
# Location of mintcasts already downloaded.
[ -d "${HOME}/Data/Downloads/mintCasts" ] && mintCastDownloadDir="${HOME}/Data/Downloads/mintCasts" || {
	printf "\n\n\tmintCast Download Directory not found. Exiting...";
	exit 65

#get mintCast URLs
printf "\n\n\tAvailble MintCasts on $mintCastSite are\n";
curl -s | sed 's/</\
</g' | sed 's/>/\
/g' | grep "href\=http\:\/\/.*mintCast[0-9][0-9][0-9].*\.mp3" | cut -d= -f2 | tee $dnList

	cd $mintCastDownloadDir/
	wget -c -i $dnList

printf "\n\n\tThese are the mintCasts available/Downloaded with Latest file at the bottom.\n"
ls -ltrh $mintCastDownloadDir/mintCast*.mp3

exit 0
what it does is to get only the URL's of mp3 files on mintCast website and see if there is already one existing in the Download directory.
if it exists then wget tries to continue & if it's already completed then leaves it as it is.

Just wanted to share the script for inputs.

Re: How to make a MintCast Automatic Download

Post by Husse »

I've changed the subject line somewhat and moved it to the howto section
Post Reply

Return to “Tutorials”