[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Doing search and replace via *grep* buffer

From: Chris Moore
Subject: Re: Doing search and replace via *grep* buffer
Date: Thu, 15 Feb 2007 15:04:48 +0100

On 2/15/07, Kim F. Storm <address@hidden> wrote:

Then hit / and type the replacement text:
  / newtext RET

Now, still in the *grep* buffer, move to the next instance you want
to modify, and just hit . to repeat the replacement, for example:
  n n . n . n . n n n .

(I suppose VI users will find this very familiar).

vi users are used to / being used to search, not to replace.  and 'N'
is the key for 'previous match', not 'p'.  The interface you offer
here is similar enough to how things work in vi to confuse people.
Also, while using 'n' and 'p' to go up and down, there's no finger
available to press '.'; some other choice of key would be better.

How about 'r' to prompt for replacement text and do a replacement, and
'g' to do it a(g)ain on a different line?  The left hand easily
reaches 'r' and 'g' while the right hand is touching 'n' and 'p'.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]