);
1 while waitpid(-1, WNOHANG);
sub forkgrep {
return if fork;
(my $regex, @ARGV) = @_;
while (<>) {
print "$ARGV: $_" if /$regex/o;
}
exit;
}
> > -Original Message-
> > From: Peter Scott [mailto:[EMAIL PROTECTED]]
> > Sent: Tuesd
ght.
>-Ron
>
>
> > -Original Message-
> > From: Peter Scott [mailto:[EMAIL PROTECTED]]
> > Sent: Tuesday, August 07, 2001 12:20
> > To: Yacketta, Ronald
> > Cc: [EMAIL PROTECTED]
> > Subject: RE: ideas to clean this up?
> >
> >
>
that would be great, but me being me I doubt it will
happen any time soon
> -Original Message-
> From: Peter Scott [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, August 07, 2001 12:20
> To: Yacketta, Ronald
> Cc: [EMAIL PROTECTED]
> Subject: RE: ideas to clean this up?
&
:[EMAIL PROTECTED]]
> Sent: Tuesday, August 07, 2001 12:20
> To: Yacketta, Ronald
> Cc: [EMAIL PROTECTED]
> Subject: RE: ideas to clean this up?
>
>
> [My rule is that beginners' questions arising from a thread on the
> beginners' list get answered on the
At 09:29 AM 8/7/01 +0200, Romek KrisztiƔn wrote:
> > And your exec code ought not to have to change. If you're used to doing
> > something that says
> >
> > foo (@files)
> >
> > then just do instead
> >
> > foo (@{$logFiles{$key})
> >
> > where $key is one of the hash keys - obv
to get at
those results, things will get more complicated and you'll probably end up
doing the regex searching in Perl, still in forked children.
>-Ron
>
> > -Original Message-
> > From: Peter Scott [mailto:[EMAIL PROTECTED]]
> > Sent: Monday, August 06, 2001 15:20
Hello!
> And your exec code ought not to have to change. If you're used to doing
> something that says
>
> foo (@files)
>
> then just do instead
>
> foo (@{$logFiles{$key})
>
> where $key is one of the hash keys - obviously now you can loop through
all
> of them.
Sorry, but di
001 15:20
> To: Yacketta, Ronald; Beginners (E-mail)
> Subject: RE: ideas to clean this up?
>
>
> At 02:51 PM 8/6/01 -0400, Yacketta, Ronald wrote:
> >Thanxs!
> >
> >now off to modify my exec code that parses an entire array
> of files :)
>
> Of course, the
At 02:51 PM 8/6/01 -0400, Yacketta, Ronald wrote:
>Thanxs!
>
>now off to modify my exec code that parses an entire array of files :)
Of course, the arrayrefs could equally well have been stored in an array
instead of a hash. There's a thin justification for a hash in the absence
of any other c
Thanxs!
now off to modify my exec code that parses an entire array of files :)
> -Original Message-
> From: Peter Scott [mailto:[EMAIL PROTECTED]]
> Sent: Monday, August 06, 2001 14:36
> To: Yacketta, Ronald; Beginners (E-mail)
> Subject: Re: ideas to clean this up?
>
At 01:55 PM 8/6/01 -0400, Yacketta, Ronald wrote:
>Folks,
>
>I have this butt ugly little perl code here,
Your honesty is refreshing :-)
>would like some ideas on really
>streamlining it and cleaning it up.
>
>opendir DIR1, "../logs/set1" or die "Can't open ../logs/set1: $!";
>opendir DIR2, "../
Folks,
I have this butt ugly little perl code here, would like some ideas on really
streamlining it and cleaning it up.
opendir DIR1, "../logs/set1" or die "Can't open ../logs/set1: $!";
opendir DIR2, "../logs/set2" or die "Can't open ../logs/set2: $!";
opendir DIR3, "../logs/set3" or die "Can't
12 matches
Mail list logo