ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ru...@us.ibm.com
Subject Re: Flexibility Syndrom
Date Tue, 07 Mar 2000 01:35:53 GMT


duncan wrote:

>> Great: everyone bails, and I'm left holding the bag?  ;-)
>
>Nope. In fact, I'm back for a bit. I'm going to try to understand what the
>heck has gone into the codebase since last November and propose
>simplification, simplification, simplification.

Welcome back!

Given your questions today, here's a synopsis of two structural changes
(Most of the rest of the changes are pretty self explanatory).

1) Nobody liked the implicit "init" tasks that were generated.  After a
suitable period of discussion, and without apparently understanding your
original design intent, I went through and made all the implicit "init"
tasks explicit.  Fortunately, if the build.xml files were changed
accordingly, then they could work with both old and new versions of ant.
Unfortunately, this will not be the case should we change it back.

2) I invented a design pattern for nested tags.  If a nested tag "foo" tag
is found, then an attempt is made to call a "createFoo" on the parent
object.  If this succeeds, then the object created will be configured as
would be any other Ant created objects.  This is nicely recursive.

Costin took advantage of this to enable support for <property> tags nested
inside of <ant> tasks.  I believe that the requirement is valid - namely
that it would be useful to have a "super project" that invokes several
nested projects with slightly varying properties.  Furthermore, simply from
an XML DTD perspective, the resulting build.xml is fairly clean.

I'm attaching a build.xml file which shows another application of nested
tasks, as applied to BSF.  You will notice workarounds to various problems
- like the automatic copying of non-Java files, and other problems like
files that are no longer part of the make but still exist in CVS and don't
compile.  (I also avoided properties as their status are uncertain at this
time).  Even so, it is simple and straightforward (IMHO).  By contrast,
take a look at xml-cocoon's build.xml which has a series of prep steps.

>In fact, I'm actually
>considering doing a "revolution" branch for a rewrite of the Ant internals
>into something smaller, lighter, and meaner (hey, I'm getting on a plane
>tommorrow and Ant is plane material for me.. :)

Can I do a preemptive +1 to whatever you create so that it will go into the
main branch straight away? ;-)

- Sam Ruby

(See attached file: build.xml)

Mime
View raw message