From: "Loris Bennett" <loris.bennett@fu-berlin.de>
To: help-gnu-emacs@gnu.org
Subject: Re: How to get count of a specific character
Date: Tue, 04 Feb 2014 15:49:35 +0100 [thread overview]
Message-ID: <87lhxrnda8.fsf@hornfels.zedat.fu-berlin.de> (raw)
In-Reply-To: bc4b3de7-4e3c-4769-8343-831ed69dabdf@googlegroups.com
Angus Comber <anguscomber@gmail.com> writes:
> I have a buffer which is a massive long line of names followed by
> semi-colon. I want to get a list of the number of names I have. I
> can highlight the region and use wc to get count of words and divide
> by 2 to get a rough measure.
>
> But it would be an easy task if I could simply get a count of the
> number of semi-colon characters?
>
> Does anyone know a way to get this?
If you do
M-x re-builder
when you are in the buffer and then enter ";" as the regex, the number
of matches will be displayed.
Cheers,
Loris
--
This signature is currently under construction.
next prev parent reply other threads:[~2014-02-04 14:49 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-04 14:29 How to get count of a specific character Angus Comber
2014-02-04 14:44 ` Nicolas Richard
2014-02-04 14:48 ` Thorsten Jolitz
2014-02-04 14:49 ` Loris Bennett [this message]
[not found] ` <mailman.13678.1391525077.10748.help-gnu-emacs@gnu.org>
2014-02-04 15:28 ` Angus Comber
2014-02-04 15:34 ` Nicolas Richard
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87lhxrnda8.fsf@hornfels.zedat.fu-berlin.de \
--to=loris.bennett@fu-berlin.de \
--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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).