From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Ken Goldman Newsgroups: gmane.emacs.help Subject: Re: Emacs and vim analogs Date: Thu, 01 Mar 2007 09:46:13 -0500 Message-ID: <45e836f2$1@news.greennet.net> References: <854ppji8yx.fsf@lola.goethe.zz> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Trace: sea.gmane.org 1172763686 22970 80.91.229.12 (1 Mar 2007 15:41:26 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 1 Mar 2007 15:41:26 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Mar 01 16:41:17 2007 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1HMnOq-0006pt-M6 for geh-help-gnu-emacs@m.gmane.org; Thu, 01 Mar 2007 16:40:56 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HMnOs-00041w-F6 for geh-help-gnu-emacs@m.gmane.org; Thu, 01 Mar 2007 10:40:58 -0500 User-Agent: Mozilla/5.0 (X11; U; AIX 000C89FF4C00; en-US; rv:1.7) Gecko/20040617 X-Accept-Language: en-us, en Original-Newsgroups: gnu.emacs.help In-Reply-To: Original-NNTP-Posting-Host: 192.91.197.52 X-Original-NNTP-Posting-Host: 192.91.197.52 Original-X-Trace: 2 Mar 2007 09:38:42 -0500, 192.91.197.52 Original-Lines: 24 Original-Path: shelby.stanford.edu!newshub.stanford.edu!postnews.google.com!news4.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!nx02.iad01.newshosting.com!newshosting.com!newspeer.monmouth.com!newspeer1.nwr.nac.net!feedme.ziplink.net!news.greennet.net!192.91.197.52 Original-Xref: shelby.stanford.edu gnu.emacs.help:145954 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:41560 Archived-At: M G Berberich wrote: >>"Clinton Curry" writes: > >>>2) Redo-last-change. In Vim, if you make a change, pressing "." >>>will make the change again. Is there something analogous in Emacs, >>>aside from defining a macro? >> >>Either C-x M-ESC or C-x z, depending on your requirements. > > > You probably mean C-x ESC ESC or C-x M-: . C-x M-ESC simply quits my > emacs. But both are not doing what '.' does in vim. With vims . you > can repeate commands like “replace next three word with …”, “indent 5 > lines”, “append … to line” or “replace rest of line with …” > (where … stands for some text). This is not possible with emacs > because there is no implicit grouping of inserted characters, so C-x z > repeats the last character typed, which is completely useless. The statement "This is not possible with emacs" is typically false. Complex commands such as you describe are easily done with keyboard macros. There are so useful that I have the start, end, and execute functions assigned to function keys.