[PLUG] phone number regex

Felix Lee flee at aracnet.com
Fri Jun 7 21:15:25 UTC 2002


Rich Shepard <rshepard at appl-ecosys.com>:
>   The file is a comma-and-quote delimited text file dumped from my
> addressbook in jpilot. I want to strip out all telephone numbers which are
> in the format "xxx-xxx-xxxx" by searching for them and replacing them with
> nothing.

[0-9][0-9][0-9]-[0-9][0-9][0-9]-[0-9][0-9][0-9][0-9]

There isn't a simpler regexp in emacs that will match that
exactly.  (This is emacs 20.7; I haven't looked at what
changes emacs 21 introduced yet.)
--
[ sometimes these boots are made for booting ]




More information about the PLUG mailing list