SLUG Mailing List Archives
Re: [SLUG] search and replace multiple files?
- To: slug@xxxxxxxxxxx
- Subject: Re: [SLUG] search and replace multiple files?
- From: Sonia Hamilton <sonia@xxxxxxxxxxxx>
- Date: Tue, 2 Aug 2011 14:24:47 +1000
- Dkim-signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=date:from:to:subject:message-id :references:mime-version:content-type:in-reply-to; s=smtpout; bh=/F/Vjw2lh9YgO9mVVSk4/fZJhQw=; b=Sx+NNJqXc39f7Vkdb1SHQjV5J3BL Yt1Iq4MYJhTEaCDMkkV1Ice0rcHz0Ez69gpPD//ZPXdhaA9Zu1F0iYCefsQk8SCc uj35efx0Aqbfh1zbizrZDfE5VwEzx9rH1xWQNTndLrQhH2zyetCiA8LqtXkuH9N0 uAGeusAGRcpxZNg=
- User-agent: Mutt/1.5.20 (2009-06-14)
* Nick Andrew <nick@xxxxxxxxxxxxxxx> [2011-08-02 12:23:43 +1000]:
> On Tue, Aug 02, 2011 at 10:29:44AM +1000, Sonia Hamilton wrote:
> > For example, I want to replace "def fubar" with "def snafu" across 50
> > files.
> perl -p -i -e 's/def fubar/def snafu/g' *
I said: "PS I know about sed, and how to edit multiple files in vim
." Supplying a perl recipe therefore isn't very useful. Perhaps I
should've said "ditto for ruby, perl, python, ...".
> If you are not using SCM (or git in particular), then you should be.
Again, not the question I was asking...