ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mariano Benitez <>
Subject how to set a property with a regexp
Date Fri, 09 May 2003 12:17:35 GMT
I have the following problem:

I have a fileset that I want to convert to the manifest classpath. so 
this is what I do:

1) pathconvert
        <property name="lib.dir.sep" 
        <pathconvert refid="project.class.path" 
property="manifest.class.path" pathsep=" ">
            <map from="${lib.dir.sep}" to=""/>
        <echo message="${manifest.class.path}"/>

2) the problem comes when trying to make this work fine on both win with 
cygnus and unix.
    the paths in the fileset comes with the path separator of the target 
os, so I change my map so that reflect that.
    the problem is that if the fileset contains another subdirectory 
like lib/tomcat/catalina.jar, the result of the mapping is different on 
each platform,
        in unix is "tomcat/catalina.jar" and in windows is 

3) now, how can I set another property but replacing ${file.separator} 
with /?

any suggestions are appreciated!


View raw message