rscott212 has asked for the wisdom of the Perl Monks concerning the following question:
use File::Copy; use File::Basename; @errorcheck = glob ('*.log'); my $error = "ARERR"; my $errorcount = 0; foreach $logrecord (@errorcheck) { open (LOGFILE, "$logrecord"); while (<LOGFILE>) { my $logline = $_; if ($logline =~ /$error/) { $errorcount++; } } if ($errorcount ne 0) {system ('page Mike');} } print "$errorcount\n"; close (LOGFILE);
Thanks in advance for any assistance you can give me!!
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: A single action from one or more items searched for
by VSarkiss (Monsignor) on Apr 17, 2002 at 19:08 UTC | |
|
Re: A single action from one or more items searched for
by grep (Monsignor) on Apr 17, 2002 at 19:06 UTC | |
|
Re: A single action from one or more items searched for
by dsb (Chaplain) on Apr 17, 2002 at 19:28 UTC | |
| A reply falls below the community's threshold of quality. You may see it by logging in. |