mozart has asked for the wisdom of the Perl Monks concerning the following question:

This node falls below the community's minimum standard of quality and will not be displayed.

Replies are listed 'Best First'.
Re: loop in C prompt window
by Joost (Canon) on Aug 27, 2007 at 17:32 UTC
    Well, you CAN do this in perl, but from your description I would think a simple shell script would be more straightforward
    #!/bin/sh command1 arg1 arg2 ... command2 etc etc etc
    update: to clarify, that script is supposed to run on the machine your terminal connects to. That usually is far simpler than trying to control programs remotely.

    also: what's a C terminal? All references on the first google results page say it's some sort of amino acid.

    A reply falls below the community's threshold of quality. You may see it by logging in.
Re: loop in C prompt window
by ikegami (Patriarch) on Aug 27, 2007 at 17:36 UTC
    Sounds like you mean "shell" when you say "C terminal". One solution would be to pipe the output of your script to a shell:
    script.pl | sh

    If you want to do something interactively, you could run sh as a child process using IPC::Open3 or Expect (or numerous other ways).

Re: loop in C prompt window
by starX (Chaplain) on Aug 27, 2007 at 18:10 UTC
    Mozart, out of curiosity, is this a windows or a Unix/Linux environment you're working in?
    A reply falls below the community's threshold of quality. You may see it by logging in.