ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject Re: Path & dir separators (was Re: Ant Principles)
Date Thu, 20 Apr 2000 23:58:57 GMT

Thomas Haas wrote:
> Actually it is not that bad, as createScrdir can return the object
> implementing the "element" element of path. The example will become:
> <copydir>
>    <srcdir url=""/>
>    <destdir file="../lib"/>
> </copydir>
> Which for sure is longer than  <copydir srcdir="../foo/"
> but still acceptable, if we go the purist way.
> HOWEVER I have lost track of the creatXXX, setYYY and addZZZ discussion
> do not know if the example above is possible. Anyone?

Yes.  The proposals don't change what XML can be supported, but how.  We
evolved our way into the current support, and James is looking into going
back and cleaning it up.

I was waiting until he poked his head back into this mailing list, but he's
probably doesn't have access to e-mail at the moment (he's traveling).

My two cents: we can certainly continue to support the current syntax to
handle the common cases.

In cases where more complex parameters are required (os specific options
and the like), then we should consider separate elements that are parellel
to tasks instead of embedded inside the task.  I reason that paths are
often referenced in multiple places in a build.xml, so this can reduce the
overall size.  In case this is not clear, an abbreviated example
(attributes not relevant to the example are omitted):

  <target name="main">
    <directory id="work" path="../build"/>
    <javac destdirId="work"/>
    <jar basedirId="work"/>

- Sam Ruby

View raw message