Why other people are making such a meal of this I do not know. Here's the easy way:
my $pid = open PIPE, "theCommand arg1 arg2 |" or die $!; my @input = map scalar <PIPE>, 1 .. 4; ## kill 3, $pid;
In reply to Re: How to read from shell command and terminate it afterwards?
by BrowserUk
in thread How to read from shell command and terminate it afterwards?
by Wen
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |