in reply to Directing STDOUT of called perl script to a variable within a calling perl script

IPC::System::Simple would be a good way to handle this.
#!/usr/bin/perl use strict; use warnings; use IPC::System::Simple qw/capturex/; my $cap = capturex("perl", "/root/Desktop/abc.pl"); die "Couldn't capture output: $!" unless $cap; print $cap;
  • Comment on Re: Directing STDOUT of called perl script to a variable within a calling perl script
  • Download Code