Beefy Boxes and Bandwidth Generously Provided by pair Networks chromatic writing perl on a camel
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: Invoking Perl script from a perl script

by rafl (Friar)
on Oct 30, 2006 at 05:31 UTC ( #581210=note: print w/ replies, xml ) Need Help??


in reply to Invoking Perl script from a perl script

You could use do or require or eval combined with something that reads the file to execute. Safe is a slightly other way to eval some code. Another way, if you don't want to run the other script in the same interpreter as the current one, is to use system or something similar combined with $^X:

system($^X, 'other_perl_script.pl', 'foo', 'bar');

Cheers, Flo


Comment on Re: Invoking Perl script from a perl script
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (5)
As of 2014-04-18 04:31 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    April first is:







    Results (461 votes), past polls