Mailinglist Archive: opensuse (3644 mails)

< Previous Next >
programming question
  • From: Alberto Santana <santana@xxxxxxxxxxx>
  • Date: Thu, 28 Mar 2002 19:54:57 -0500
  • Message-id: <3CA3BB61.8F6B3C10@xxxxxxxxxxx>
Hi guys,

Maybe this is not the place for this... but I hope somebody can help.

Suppose I have a Perl script that will (basically) do something like
this (from cron):

$output=`lynx -dump
http://lists.suse.com/archive/suse-linux-e/2002-Mar/`;
$send_it=`mail me\@here.com<$output`;

OK, here comes the problem. What if list.suse.com is down? lynx will
keep trying for a while until it gives up or something.
Is it possible to impose a time limit, like: execute $output, wait for
45 seconds, if there was no response (lynx did not dump), exit(0);

cheers,
A

PS.
Solutions based on Python, bash, tcsh, etc. are welcome 2.

--
Powered by SuSE Linux 7.1 (http://www.suse.com)

< Previous Next >
This Thread
  • No further messages