in reply to system call vs. back quotes
Using the system call is also useful when you want to control how the parameters are split. It is a more flexible way of running programs than either open or backticks.# All similar in functionality `tar czf /tmp/stuff.tar.gz /stuff` open ("tar czf /tmp/stuff.tar.gz /stuff"); system ("tar czf /tmp/stuff.tar.gz /stuff"); system ("tar", "czf", "/tmp/stuff.tar.gz", "/stuff"); # Don't search path, specify explicitly system ("/bin/tar", "czf", "/tmp/stuff.tar.gz", "/stuff");
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: system call vs. back quotes
by Vavoom (Scribe) on Jan 25, 2002 at 03:49 UTC | |
by impossiblerobot (Deacon) on Jan 25, 2002 at 08:52 UTC | |
by ton (Friar) on Jan 25, 2002 at 05:34 UTC |