You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by Torsten Pflicke <To...@entranet.co.uk> on 2000/07/26 14:49:44 UTC

Substitutions in ANT

I'm looking at ANT to use for building
some project and I've got some questions.

Replace, keySubst and Filter substitute
strings with strings. 

Q1) Are there any plans to add regular expressions, e.g.
    the jakarta-regexp stuff? I know that might cause
    problems with ant variables but surely there is some
    escaping.  

Q2) Any way to insert special characters like <CR>, <LF> etc.?

Q3) using Filter - what's their scope, i.e. do they 
   effect all file/dir copy operations or only the next
   one or all subsequently declared but not the previously
   declared ones? The documentation is not clear about it.

Cheers,
T

Re: Substitutions in ANT

Posted by Stefan Bodewig <bo...@bost.de>.
>>>>> "TP" == Torsten Pflicke <To...@entranet.co.uk> writes:

 TP> Q1) Are there any plans to add regular expressions,

It has been discussed but nobody took the stab.

 TP> Q2) Any way to insert special characters like <CR>, <LF> etc.?

Not that I was aware of. There has been a contributed task that would
do multi line replace operations, I'm going to look into adding it
during the next week (if my schedule works out).

 TP> Q3) using Filter - what's their scope,

they are global and will be used in every copy task if you request
filtering.

Stefan