David- http://ant.apache.org/manual/OptionalTasks/replaceregexp.html replace OldProperty with NewProperty in all *.properties file in current folder <replaceregexp byline="true"> <regexp pattern="OldProperty=(.*)"/> <substitution expression="NewProperty=\1"/> <fileset dir="."> <includes="*.properties"/> </fileset> </replaceregexp>
HTH, Martin-- --------------------------------------------------------------------------- This e-mail message (including attachments, if any) is intended for the use of the individual or entity to which it is addressed and may contain information that is privileged, proprietary , confidential and exempt from disclosure. If you are not the intended recipient, you are notified that any dissemination, distribution or copying of this communication is strictly prohibited. --------------------------------------------------------------------------- Le présent message électronique (y compris les pièces qui y sont annexées, le cas échéant) s'adresse au destinataire indiqué et peut contenir des renseignements de caractère privé ou confidentiel. Si vous n'êtes pas le destinataire de ce document, nous vous signalons qu'il est strictement interdit de le diffuser, de le distribuer ou de le reproduire. ----- Original Message ----- From: "David Jacobsen" <[EMAIL PROTECTED]> To: <user@ant.apache.org> Sent: Tuesday, March 27, 2007 5:05 PM Subject: replace and replaceregexp - Multi line tokens or substitution expressions ? > > Hi, > > Iâ?Tm a techwriting who has been using ANT for Search/Replaces operations > across loads of HTML files using replace and replaceregexp. > > Does anyone know if there is way for a token to include multiple lines? I > want to strip four lines from HTML files. > > <li> > <p class="ListNumber" style>Delete me.</p> > > </li> > > > Iâ?Tm on Windows. > > C:\RoboHelpTemp>java -version > java version "1.5.0_11" > Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_11-b03) > Java HotSpot(TM) Client VM (build 1.5.0_11-b03, mixed mode) > > > C:\RoboHelpTemp>ant -v > Apache Ant version 1.7.0 compiled on December 13 2006 > > > > > > --------------------------------- > Don't get soaked. Take a quick peek at the forecast > with theYahoo! Search weather shortcut.