good chemistry is complicated, and a little bit messy -LW |
|
PerlMonks |
How to get installtion Perl modules log?by Misha (Acolyte) |
on Oct 23, 2007 at 13:47 UTC ( [id://646685]=perlquestion: print w/replies, xml ) | Need Help?? |
Misha has asked for the wisdom of the Perl Monks concerning the following question:
Hi Monks Sorry for asking again but am really stuck with this. I need to collect output of Perl modules installation. I am running on UNIX environment. I am installing Perl modules (via Perl script) by using following command: system (" perl -MCPAN -e 'install Bundle::Snapshot_2007_07_23_00' ") The installation completed successfully. In order to collect logs and see the output on the screen (because installation of some models is interactive) I did following changes: system (" perl -MCPAN -e 'install Bundle::Snapshot_2007_07_23_00' | './1.pl' ") when 1.pl is very simple: while ($tmp = <STDIN> || $tmp = <STDERR>) { print $tmp; write_to_log($tmp); } Now have 3 problems: 1. The interactive questions which were during installation are missing. 2. The program stuck during the modules installation. 3. The output is different from what I have before and some important parts are missing. How I can solve those problems? Is there other way to collect Perl module installation logs? Many thanks
Back to
Seekers of Perl Wisdom
|
|