ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From isaacsteele <isaac.ste...@zoominfo.com>
Subject Re: build dependencies and executing independent targets in the same project
Date Mon, 14 Sep 2009 19:57:26 GMT

Apologies about placing it in this question in the wrong forum, should I copy
the post and re-submit it there?

I'm using subant because it is calling my tests for multiple projects in
multiple directories:

<target name="test">
	<subant>
		<fileset dir="../../" includes="**/build.xml" excludes="**/abc/build.xml,
**/xyz/build.xml">
		<target name="test"/>
	</subant>	
</target>

This calls ~15 different build.xml files for projects that I want to test
that I built previously my overall project build.xml.

If there is a better way to do this (with with the junit task), I'd love to
use it, but I don't know how at this point.


Stefan Bodewig wrote:
> 
> [Isaac, this really is a qiestion for the user list, not the dev list
> which is about the development of Ant itself, not developing with Ant.]
> 
> On 2009-09-14, isaacsteele <isaac.steele@zoominfo.com> wrote:
> 
>> 1) Is this possible--that I execute a target at the end of a build
>> regardless of failure?
> 
> Not out of the box, no.  There are patches to enable this and I think
> I've even seen somebody implement a BuildListener that will invoke a
> target in the *finished event (which sounds dangerous given that the
> project instance thinks the build is over).
> 
>> 2) What should my default target be (if I have two independent targets
>> that
>> should be built)?
> 
> Probably something like <target name="do-all-of-it" depends="C,D"/>
> 
>> 3) I know I could use <failonerror> in subant and then make D dependent
>> on
>> C, but then the build isn't marked as failed when finished.
> 
> In the part I've snipped, you said C would fail if a test failed.  do
> you really need subant at all?  If not, then make <junit> set a property
> instead of making the build fail and later use <fail/> if that property
> has been set.
> 
> Stefan
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
> For additional commands, e-mail: dev-help@ant.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/build-dependencies-and-executing-independent-targets-in-the-same-project-tp25436635p25442452.html
Sent from the Ant - Dev mailing list archive at Nabble.com.


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


Mime
View raw message