my $line; open(OUTPUT, "|command that gets output") or die "dead"; while(<OUTPUT>) { if (/Buffers/) { $line = <OUTPUT>; last; } } close(OUTPUT);
melguin
In reply to Re: Getting the next line after a match
by melguin
in thread Getting the next line after a match
by dthacker
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |