Hello Monks,
One of the first things my web-based application does is run another program. The problem is that this program prints a bunch of stuff I am not interested in to STDOUT, which means that if I use system(), all of that stuff is printed to the browser, followed by the html text of my webpage.
What I want it to do is ignore all of that stuff being sent to STDOUT by this other program and wait until this other program is finished before continuing.
I know that this other program is done because it creates a text file that is parsed by the rest of my program.
My current hack is to use backticks to collect that STDOUT junk and wait until it is possible to open the text file before continuing:
my $out = `"python extractx.py $folder/junction.fasta"` wait until(open NULL, "$folder/junction.fasta.allseqs.txt");
This is all I could come up with, but I'm assuming that I could also temporarily change where STDOUT goes until the program is done, and then change it back to the default, but I'm not sure if that is possible or how to do it.
Thanks in advance for any help.
In reply to STDOUT Issues by nodice
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |