Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much

Re: Unable to store the command output from Net::SSH2. Please help.

by perl514 (Pilgrim)
on Nov 06, 2012 at 18:56 UTC ( #1002559=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download

  1. or download this
    use Modern::Perl;
    my $ssh = Net::SSH::Any->new ($host, user => $user, password => $passw
    my @output = $ssh->capture2("ls -l");
    say "@output";
  2. or download this
    Use of uninitialized value $output[0] in join or string at 
    +line 10.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1002559]
[stevieb]: agreed. That's why I said at least a half-dozen. If enough of the different formats are present, the date/time folk may not have to request more. If they do, then at least there was a decent base to start with
[stevieb]: I do date and time transformations in both Perl and Python, but not frequently enough to not have to search for the format params etc ;)

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (4)
As of 2017-04-29 02:42 GMT
Find Nodes?
    Voting Booth?
    I'm a fool:

    Results (531 votes). Check out past polls.