Hi all,
So, I'm guessing that Ant 1.7+ (with optional Ant-Contrib) doesn't support
negative lookahead regex searches.
So, I'm refocusing on the main objective here: I want a propertyset that excludes properties matching certain patterns. Any idea as
to how to accomplish this?
Thanks!
Steve Amerige
SAS Institute, Deployment Software Development
On 11/9/2011 3:40 PM, Steve Amerige wrote:
Hi all,
Is negative lookahead supported at all in Ant 1.7 and higher (Ant-Contrib,
too)? Maybe my syntax is off:
<propertyregex property="result" input="a.b.c.bad" select="\1" regexp="(.*(?!bad))"
defaultValue="" override="true"/>
<propertyregex property="result" input="a.b.c.ok" select="\1" regexp="(.*(?!bad))"
defaultValue="" override="true"/>
The first result should be the empty string and the second result should be "a.b.c.ok". I'm also looking to use this idea in
<propertyset> to exclude certain properties.
See the regular expression page on this:
http://www.regular-expressions.info/lookaround.html