while ( <$inFH> ) { m#cpuinfo\nvendor_id\s+:\s(.*?)\n# and print "CPU:\t$1" and last; }
I hope this is helpful.
Cheers,
JohnGG
In reply to Re: Grepping with Perl: How to stop after first match?
by johngg
in thread Grepping with Perl: How to stop after first match?
by paulnovl
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |