Re: Small Project for a Lucky Person
- Posted by Alexander Toresson <alexander.toresson at gmail.com> Nov 29, 2005
- 551 views
Alexander Toresson wrote: > > Alexander Toresson wrote: > > > > cklester wrote: > > > > > > Hey! I need a program that will retrieve a web page at set intervals. > > > Anybody > > > got something like this or want to make it for me? 8) Thanks!! > > > > > > > #!/bin/sh > > > > while [ true ] > > do > > wget $1 > > sleep $2 > > done > > > > Could easily be trsnalated to euphoria and run in windows if you download > > wget > > for windows. > > > > Sorry, should have been wget -r $1, not wget $1. The latter caused wget to not > replace an existing file, rather rename it. I figure you wanted the former. > Btw, $1 is the first command line option (file to download), $2 is the second > one (the number of seconds to wait between downloads). > Hehe, was wrong again :) -r does have the desired effect, however, it also triggers recursive downloading (which is not at all what we want). -N does the right thing, with the added niceness that it doesn't download the file if the timestamp on the local file is as new as or older than the file being downloaded. Regards, Alexander Toresson