help-gnu-emacs
[Top][All Lists]
Advanced

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

Regepxp-help: Replacing foo with bar but not foo.*


From: Patrick Drechsler
Subject: Regepxp-help: Replacing foo with bar but not foo.*
Date: Fri, 18 Aug 2006 22:19:22 +0200
User-agent: Gnus/5.110006 (No Gnus v0.6) Emacs/22.0.50 (gnu/linux)

Hi,

how do I replace the term `foo' with `bar' when `foo' is followed
by a conditional term? Or what do I have to pass as argument to
`M-x replace-string'?

the rule I'm trying to imply is "replace foo if it is not
followed by a dot".

INPUT

foo jfkda
foo.bar fdjak

OUTPUT

fooMYREPLACEMENT jfkda
foo.bar fdjak


TIA

Patrick
-- 
"If you choke a smurf, what color does it turn?"



reply via email to

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