ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Bodewig <bode...@apache.org>
Subject Re: propertyregex
Date Tue, 02 Sep 2008 13:33:29 GMT
On Tue, 2 Sep 2008, Yannick Feuzet <guyyannick@hotmail.com> wrote:

> I want to attain the following String manipulation: 
> 
> 200802  2008/02
> 
> ich wrote the followinfg code bat is not working. Can somebody help
> me. Thanks
> 
> <propertyregex     property="adjustedDate" 
>                                 input="${date}" // 200802
>                                 regexp="([0-9]{5})([0-9]{2})" 
>                                 replace="\1/\2"/>

First of all, you realize that propertyregexp is not a task provided by
Ant but the ant-contrib project which is separate and provides a user
forum of itself, do you?

I think the first group of your regexp is meant to contain {4}, not
{5}.

Stefan

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


Mime
View raw message