Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 26 Dec 2001 12:26:17 +0100
From:      Rogier Steehouder <r.j.s@gmx.net>
To:        Nils Holland <nils@tisys.org>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: Questions to all script wizards out there...
Message-ID:  <20011226122617.A873@localhost>
In-Reply-To: <20011224192919.A89314@tisys.org>; from nils@tisys.org on Mon, Dec 24, 2001 at 07:29:19PM %2B0100
References:  <20011224192919.A89314@tisys.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On 24-12-2001 19:29 (+0100), Nils Holland wrote:
> I would like the script to use wget in order to fetch the program listing
> of a radio station from the station's website. I would like to have seven
> days fetched in advance.
> 
> Now, the URL always looks like this:
> http://www.dradio.de/dlf/vorschau/<year>/<month>/<day>.html
> 
> So in order to make wget fetch today's program, I'd run it like this:
> 
> wget -options http://www.dradio.de/dlf/vorschau/2001/12/24.html

In a bourne shell:

for i in 0 1 2 3 4 5 6; do
    wget -options http://www.dradio.de/dlf/vorschau/`date -v +${i}d +'%Y/%m/%d'`.html
done

You don't even need a script :-)
(Though it makes it easier)

With kind regards, Rogier Steehouder

-- 
                          ___                          _
-O_\                                                  //
 | /               Rogier Steehouder                 //\
/ \                  r.j.s@gmx.net                  //  \
  <---------------------- 25m ---------------------->

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20011226122617.A873>