ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dominique Devienne" <>
Subject Re: Reporting build success/failure in <ant>/<subant>'s output log file?
Date Wed, 09 May 2007 20:36:26 GMT
On 5/9/07, Andrew Bayer (abayer) <> wrote:
> > I'd like to hand a graph of builds to run (from Ivy) and have
> > <subant>
> > detect a failure and skip all dependencies, then carry on with
> > everything else. So at the end of the <subant> run, we'd report
> >   -failing builds
> >   -skipped builds
> > then it would halt.

Hmmm, sounds strangely familiar.... Ah yes, GUMP! That's not the realm
of Ant IMHO.

> That's basically what I'm looking for - we have enough projects that are
> not all directly related to each other that it's a huge help for us to
> attempt to build every project, even if an early one fails, so that we
> can see if there are unrelated errors in later projects, etc... Ideally,
> I'd also like to be able to have subprojects be able to tell if any
> previously-run subprojects have failed, because we've got a couple
> projects that interact with our packaging and distribution systems that
> behave in different ways depending on whether the compilation projects
> have all passed or not.

A large build like this which takes different actions depending on
success/failures of sub-builds will be a huge maintenance headache.
Ant is not designed to be used like this, and consequently makes it
hard to do this. You'd be better off writing the "orchestrating" logic
using a true scripting language like Python (hmm, that GUMP reference
coming up again ;-) on top of your existing Ant builds for each

That said, you may be able to work something out without having to
hack the Ant code itself by writing a custom BuildListener that writes
out to a file success/failure info about your various
builds/subbuilds, that you can query from your builds (using existing
tasks wrapped in macros, or custom tasks). (the build listener could
also set properties, but on which build (Project)???)


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message