I feel as though there should be a simple way to do this, but searching around gives me no good leads. I just want to open()
a pipe to an application, write some data to it, and have the output of the subprocess sent to the STDOUT
of the calling script.
open(my $foo, '|-', '/path/to/foo');
print $foo 'input'; # Should behave equivalently to "print 'output'"
close($foo);
Is there a simple way to do this, or have I hit upon one of the many "can't get there from here" moments in Perl?