Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: "ack" and replace in a directory... in Windows?

by Anonymous Monk
on Feb 29, 2012 at 02:19 UTC ( [id://956826]=note: print w/replies, xml ) Need Help??


in reply to "ack" and replace in a directory... in Windows?

Populate @ARGV

So  $ perl -i -p -e ' BEGIN { @ARGV = `ack -f --perl`; }  s/foo/bar/g; "

See Iterator::Files and Iterator::Diamond

Replies are listed 'Best First'.
Re^2: "ack" and replace in a directory... in Windows?
by mascip (Pilgrim) on Feb 29, 2012 at 12:17 UTC

    It tries, but fails due to

    Can't open foo.pm (and others) : Invalid argument.

    Thank you though :o)

      chomp @ARGV;

      Also, «-e '» should have been «-e "».

      - tye        

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (3)
As of 2024-04-19 05:33 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found