Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: issue with grep in the output of a command

by pme (Prior)
on Jul 25, 2015 at 12:49 UTC ( #1136283=note: print w/replies, xml ) Need Help??


in reply to issue with grep in the output of a command

Hi janasec,

You can split and grep like this:

use Data::Dumper; my @out = grep /FC_DVT/, split("\n", $out); print Dumper( \@out ) . "\n";
and the output is
$VAR1 = [ 'cfg: FC_DVT MEZZI; MEZZI1', 'cfg: FC_DVT' ];
UPDATE 'use' line was edded.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1136283]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (7)
As of 2020-01-28 19:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Notices?