Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re: running command from within perl script

by amir_e_a (Hermit)
on Oct 11, 2010 at 19:47 UTC ( #864685=note: print w/replies, xml ) Need Help??


in reply to running command from within perl script

The simplest way is to use the "system" function.

If you want to capture the output of the program, use backticks:

my $program_output = `programname`;

For a more advanced, but harder to use way to do the same thing, see IPC::Open3.

  • Comment on Re: running command from within perl script

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (10)
As of 2019-12-10 13:11 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?