ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Eric Wood" <>
Subject Strip a dirname from a property that represents a path
Date Thu, 09 Apr 2009 18:31:40 GMT
I have a property that is a path reference to a jar file and I want to
get the directory name for the element.  The task dirname works with a
file to set a property, but is there a simply solution to grabbing the
path to from a file.  I assume that I could use the ant-contrib
PropertyRegex task, but was thinking that there is a simpler more
elegant solution.  Any thoughts?
<property name="pmd.jar" value="/release/pmd/pmd/4.1/pmd-4.1.jar" />
what I want is a property for the "release/pmd/pmd/4.1" directory.
Thanks, Eric

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message