Re: Downloading the APOD from Safari
Re: Downloading the APOD from Safari
- Subject: Re: Downloading the APOD from Safari
- From: Christopher Stone <email@hidden>
- Date: Fri, 07 Sep 2012 12:02:24 -0500
On Sep 07, 2012, at 11:28, Christopher Stone < email@hidden> wrote: This will create one if necessary, and the mkdir command will fail silently if it already exists.
______________________________________________________________________
Let's neaten that up a trifle:
do shell script " apodDIR=~/\"Pictures/APOD_Images/\"; mkdir \"$apodDIR\" 2>/dev/null; uPTH=`curl -s \"$bURL\" | awk -F\\\" '/href="" { print $2 }'`; uNM=`awk -F/ '{ print $NF }' <<< $uPTH`; curl -s \"$bURL$uPTH\" -o \"$apodDIR`date '+%Y%m%d ยป '`$uNM\"; "
-- Best Regards, Chris
|
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden