Christoph's Perl Snippets

Files

Pipe into a command and read the result

open2(*read1,*write1,"/usr/local/bin/command");
print write1 "input for the process";
$output = <read1>;
print "Process said: $output\n";

WorkaroundOrg: PerlTricks (last edited 2005-07-14 14:59:27 by ChristophHaas)