curl command returns a success and when I run the script it prints to stderr and I can see it on console. How to capture response of curl and why it prints stdout of curl command to stderr of my script. What is the correct way to do this with pipes.my $postjson = ''; ## a big input normally my $response= open(PIPIE,'|curl -d @- destination') or die "smth"; print PIPIE $postjson; close PIPIE;
In reply to capturing stdout of pipe by brscvs
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |