ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel Barclay <Daniel.Barc...@digitalfocus.com>
Subject does Ant work with absolute file pathnames?
Date Thu, 10 May 2001 19:58:19 GMT
Are the various tasks in Ant compatible with using absolute file pathnames?

I've been running into a number of places where tasks expect a file pattern 
but don't seem to work with absolute file pathnames.

For example, I'm trying to do something like this:

  in project\module2\build.xml:

  <war ... >
    ...
    <lib dir="."
      <include name="${module1.jarName}" />
    </lib>
  </war>

The value of property module1.jarName is an absolute file pathname (e.g., 
"C:\project\module1\build\result.jar").

Because the "name" attribute of the "include" element of a FileSet-based
element (e.g., the "lib" element) is a file pattern, absolute pathnames 
don't seem to work.

Is there any way to specify an absolute pathname?

If not, is there a design flaw in Ant that many of its tasks don't
handle absolute pathnames?  Or must Ant be used with relative pathnames?
Or do you have to define more properties (to split some parent or
ancestor directory name from the remainder of the pathname of a file)?


Thanks,
Daniel
-- 
Daniel Barclay
Digital Focus
Daniel.Barclay@digitalfocus.com

Mime
View raw message