ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Emmanouil Batsis <>
Subject [solved] Task allows nested mapper but not regexpmapper with handledirsep (was Re: Help with (regexp?) file mapper)
Date Tue, 28 Jun 2005 08:43:17 GMT
Dominique Devienne wrote:

>> i just defined a project property to use within mappers and that
>>works well.
>Do you mind describing your solution in more details, to help those
>who search the mailing list archive?
>BTW, did you try \${file.separator}? 

That wouldn't work on my linux box right? I switch between a windows 
machine at work and my linux laptop frequently, so i initially added an 
entry in my build properties:

# controls the path seperator to use in regexp mappers,
# use "/" on unixish systems and "\\\\" on wonblows (no quotes)

and used it like

<mapper type="regexp" from="(.*)${mapper.dir.seperator}(.*).xml"

However, Peter Reilly's way removes the need to maintain a property and 
allows the use of handledirsep by just nesting the mappers:

      <regexpmapper handledirsep="true" from="(.*)/(.*).xml" 
to="\1/web/\" />

Thanks all.


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message