ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Murray, Mike" <...@ptc.com>
Subject RE: pathconvert with regexpmapper
Date Fri, 15 Oct 2004 21:10:53 GMT
Thanks for the alternative expression, but my problem is that I can't figure how to get pathconvert
to accept a regexp mapper.

BUILD FAILED
The <pathconvert> type doesn't support the nested "mapper" element.

-----Original Message-----
From: Matt Benson [mailto:gudnabrsam@yahoo.com]
Sent: Friday, October 15, 2004 3:44 PM
To: Ant Users List
Subject: Re: pathconvert with regexpmapper

Mike:  try

<mapper type="regexp"
        from="^[A-Z,a-z]:(.*)" to="\1" />
HTH,
Matt

--- "Murray, Mike" <mbm@ptc.com> wrote:

> Does anyone have an example of acceptable syntax for using a regexp mapper in a pathconvert?
 
>  
> I've tried many ways, but none work.  The documentation says more complex nested mappers
are supported. 
>
http://ant.apache.org/manual/CoreTasks/pathconvert.html
>  
> Thanks, Mike
>  
>  <!-- strip drive reference - X\:\\ OR X\:/ -->
>  <mapper id="strip_drive" type="regexp" from=".?\\:[/\\]\\?(.*)$$" to="\1"/>
> 
>  <pathconvert targetos="unix" property="modroot_location">
>    <path>
>      <pathelement location="${modroot}"/>
>    </path>   
>    <regexpmapper from=".?\\:[/\\]\\?(.*)$$" to="\1"/>
>  </pathconvert> 
>  
>    <mapper type="regexp" from=".?\\:[/\\]\\?(.*)$$" to="\1"/>
>    <map type="regexp" from=".?\\:[/\\]\\?(.*)$$" to="\1"/>
>    <map refid="strip_drive"/>
> 

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


Mime
View raw message