Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re^2: problem in running UNIX command through perl

by marcussen (Pilgrim)
on Oct 28, 2008 at 00:53 UTC ( #719875=note: print w/replies, xml ) Need Help??


in reply to Re: problem in running UNIX command through perl
in thread problem in running UNIX command through perl

The quotes shouldn't interfere and would be required if he had spaces in his filenames for example

Confucius says kill mosquito unless cannon
  • Comment on Re^2: problem in running UNIX command through perl

Replies are listed 'Best First'.
Re^3: problem in running UNIX command through perl
by mpeever (Friar) on Oct 28, 2008 at 01:43 UTC
    It sometimes makes the code more readable to delimit strings in qq{}:
    my $cmd = qq{ egrep -f "$_proj_file" "$_running_file" > "$_admin_temp_ +file" }; my $result = `$cmd`; # or even qx{$cmd}
    That keeps you from having to escape quotes, etc.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://719875]
help
Chatterbox?
[Discipulus]: ah thanks i forgot that thread (even if i saved it in my homenode)..
[Discipulus]: the node i discovered yesterday nigth was also interesting

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (5)
As of 2016-12-06 08:48 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    On a regular basis, I'm most likely to spy upon:













    Results (101 votes). Check out past polls.