PDA

View Full Version : Using Perl to control other programs


eagle683
07-08-2005, 12:27 AM
Hey all,

I am fairly new to Perl, and I am in the process of writing a program that controls another shell program (similar to ftp), and I need to both control it using perl, and have the program react to messages such as, "permission denied" if I can't make a directory on a certain computer. Alternatitvely, is there a way I can check that it worked using the program.

The problem I am mainly encountering, is I can control the program to do whatever at the moment; however, I cannot read the output, so it just becomes stuck. The program is in its beginning stages, so I am really open to do anything with it right now.

Thanks for any help in advance.

eagle

FishMonger
07-08-2005, 02:12 AM
Why not have the Perl script do whatever the shell script is doing instead of haveing the Perl script "control" the shell script? That would make it a lot easier.