Redirect the STDERR stream. In bash, for example, you can do:
p4 where filename 2>&1This tells the p4 command to send the STDERR stream (handle 2) to handle 1 (STDOUT). I expect that the same syntax will likely work in backticks, but I've never tried it, so you'll need to verify that. There are multiple ways to redirect the I/O streams using perl, so you may want to read perldoc perlipc and perldoc -f open to start with.
...roboticus
When your only tool is a hammer, all problems look like your thumb.
In reply to Re: How to stop printing the output of a command on screen when the command fails?
by roboticus
in thread How to stop printing the output of a command on screen when the command fails?
by perl_mystery
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |