ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Bodewig <bode...@apache.org>
Subject Re: Search a substring
Date Fri, 02 Aug 2002 06:28:32 GMT
On Wed, 31 Jul 2002, Matt Benson <gudnabrsam@yahoo.com> wrote:

> Looks interesting but I can't find it in the
> documentation.

You'll need Ant 1.5 - somewhere at the end of the list of
<http://jakarta.apache.org/ant/manual/CoreTasks/conditions.html>
between filesmatch and istrue.

> Would it be specified:
> 
> <condition>
>   <contains string="Ant" substring="a"
>    casesensitive="false" />
> </condition>

Yes - but you'll have to add a property attribute to <condition> as
well.

After

<condition property="Ant contains some kind of a">
  <contains string="Ant" substring="a" casesensitive="false" />
</condition>

<condition property="Ant contains lower case a">
  <contains string="Ant" substring="a" casesensitive="true" />
</condition>

The property "Ant contains some kind of a" will be set to "true" and
the property "Ant contains lower case a" will be unset.

Stefan

--
To unsubscribe, e-mail:   <mailto:ant-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-user-help@jakarta.apache.org>


Mime
View raw message