all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Peter Dyballa <Peter_Dyballa@Web.DE>
To: C K Kashyap <ckkashyap@gmail.com>
Cc: help-gnu-emacs@gnu.org
Subject: Re: Emacs equivalent of the ":g" command in vi
Date: Fri, 22 Jul 2011 11:27:57 +0200	[thread overview]
Message-ID: <14F21CEC-7265-4DE4-888A-A10FCFFF6826@Web.DE> (raw)
In-Reply-To: <CAGdT1gpcY+Tz_5df0AE3eMvw-zJAD_3Se4aE8o_a5joRV=2Ubw@mail.gmail.com>


Am 22.07.2011 um 10:42 schrieb C K Kashyap:

> I need to perform a certain action (such as delete the line) on each line of
> a buffer if the line matches a regular expression. In vim, we can use the :g
> command for this.

I don't know that :g in vim that exactly, I prefer to use ``.´´ from time to time.

GNU Emacs allows to use three commands:

	repeat
	repeat-complex-command
	repeat-matching-complex-command

See which one can be used! (Deleting a single line is simple: C-k, deleting a bunch of lines is also quite simple: C-u <number> C-k – which could be as simple as in vi/vim.)

--
Greetings

  Pete

There's no place like ~
			– (UNIX Guru)




  reply	other threads:[~2011-07-22  9:27 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-22  8:42 Emacs equivalent of the ":g" command in vi C K Kashyap
2011-07-22  9:27 ` Peter Dyballa [this message]
2011-07-22  9:48   ` Thierry Volpiatto
2011-07-22 10:02     ` C K Kashyap
2011-07-22 10:12       ` Peter Dyballa
2011-07-22 10:41         ` C K Kashyap
2011-07-22 10:34       ` Thien-Thi Nguyen
2011-07-22 10:44         ` C K Kashyap
2011-07-22 10:45       ` Deniz Dogan
2011-07-22 10:46         ` Deniz Dogan
2011-07-22 19:03       ` Eric Abrahamsen
2011-07-22 20:27 ` MBR
2011-07-22 20:37   ` Andreas Röhler
2011-07-22 20:51     ` MBR
2011-07-23  7:10       ` Andreas Röhler
2011-08-15  0:27       ` Ken Goldman
2011-07-23  3:02   ` C K Kashyap
2011-07-23  8:44     ` suvayu ali

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=14F21CEC-7265-4DE4-888A-A10FCFFF6826@Web.DE \
    --to=peter_dyballa@web.de \
    --cc=ckkashyap@gmail.com \
    --cc=help-gnu-emacs@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.