in reply to Sub Perl Scrips

If you merely wish to run another perl script then the easiest way to do that is to use the backtick operator. Assuming that perl is accessible from your command line and that your script is named myscript.pl then just add the line:

`perl myscript.pl`;

You can even capture the output of the other perl script if any as in:

my $output = `perl myscript.pl`;

As Larry Wall always says, "There's more than one way to do it."

Replies are listed 'Best First'.
Re: Re: Sub Perl Scrips
by Fastolfe (Vicar) on Jan 28, 2001 at 02:37 UTC
    Avoid `back-ticks` unless you need to get at the output (as you do in your second example). Using back-ticks in a void context only makes perl do extra work unnecessarily. In this case, I'd use system instead.
      Why can't backticks use defined(wantarray) to find out if they where called in a void context, and if so, do not return or capture the output? (Redirecting to /dev/null comes to mind)