Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re^2: How to capture log from external interactive process

by sintadil (Pilgrim)
on Sep 17, 2004 at 14:30 UTC ( [id://391784]=note: print w/replies, xml ) Need Help??


in reply to Re: How to capture log from external interactive process
in thread How to capture log from external interactive process

rc=$? if [[ ${rc} -ne 0 ]]; then echo "cp -i $file1 $file2 failed with a value of ${rc}" fi

Thank you for reminding me of why I shall never, ever learn shell scripting and shall forever stick with Perl. :)

Replies are listed 'Best First'.
Re^3: How to capture log from external interactive process
by LessMonk (Initiate) on Sep 17, 2004 at 14:44 UTC
    Thanks for your help guys, but I'm still stumped.

    Script may well work but I need to do all this from a perl script.

    1) execute external program from perl
    2) using perl or shell scripting magic, log the programs output and user input
    3) use perl to check the exit status of the program

    I've tried using perl's open3, but then stdout/stderr/stdin all get piped to perl :(

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://391784]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others chanting in the Monastery: (3)
As of 2024-04-18 01:21 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found