ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Steve Loughran" <stev...@iseran.com>
Subject Re: exporting classpath references from inner Ant builds to outer Ant builds.
Date Thu, 23 May 2002 23:09:08 GMT

----- Original Message -----
From: "James Strachan" <james_strachan@yahoo.co.uk>
To: "Ant Developers List" <ant-dev@jakarta.apache.org>
Sent: Thursday, May 23, 2002 2:44 PM
Subject: Re: exporting classpath references from inner Ant builds to outer
Ant builds.


> From: "Erik Hatcher" <jakarta-ant@ehatchersolutions.com>
> > This sounds kinda risky in that a sub-build could stomp on properties (I
> > assume you'd want those exported back up too?) and references that you
did
> > expect to be altered.  Do you envision any mechanisms for controlling
what
> > gets exported? All references blindly?  Or some selection mechanism?
>
> I've patched the Ant task to have exportRefs="true|false" and
> exportAll="true|false" to be the opposite of inheritRefs and inheritAll.
>
> For now I decided to only export (when the flag is on ;-) those references
> or properties which don't already exist in the parent project. So this new
> feature will never overwrite anything, only add new things not already
> defined in the parent project. This seems a reasonable compromise, that
its
> safe, it won't change any references/properties if there is a clash.
>
> Seems to work pretty nicely so far; I can submit it here if anyone's
> interested, it is a minor patch. Otherwise I'll submit it to Maven...

Post it anyway, so it goes in the archives. -or file on bugzilla.

I think there is a lot we could do to improve <ant> ,including any and off
of

-failonerror + successproperty (lets you ignore but tell when ant failed)
-have some way of calling the default target from some setting of the target
attribute (target= "" calls the target named "", not the default; some
builds use this trick too)
-(controversial) better bulk invocation. Not the *.xml, but maybe you can
specify a filelist and a targetlist

I can see the value in having datatype declarations trickle back, as the
only way to do this in a large project is with xml entity references, and
that sucks. I should be able to load in references using property values to
point to the build file containing the refs.

I dont know if that should be an extension of <ant> though; <datatypeload
file="classpaths.xml"> might work; only loading the out-of-target properties
and datatype declarations, then returning the datatypes to the caller.














--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message