ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dominique Devienne" <ddevie...@gmail.com>
Subject Re: EasyAnt phases
Date Tue, 18 Nov 2008 16:26:33 GMT
On Tue, Nov 18, 2008 at 10:07 AM, Jean-Louis BOUDART
<jeanlouis.boudart@gmail.com> wrote:
> As target-group is nothing more than a "target" so if/unless attribute is
> supported.
> Exemple
> <project>
>   <target-group name="test" depends="other-targetgroup" description="..."
>                          unless="skip.test"/>
>   <target name="myTestTarget" depends="whatever" phase="test">
>     ...
>   </target>
> </project>
> By typing "ant test" you will execute ALL target related to test
> target-group

So far so good.

> By typing "ant test -Dskip.test=true"  you will not execute any target
> related to test target-group.

Hmmm, I thought a target group basically had it's depends attribute
basically rewritten to include whatever target declared itself to be
part of this group, and since if/unless apply to the target's body and
not its dependencies, if/unless would have been useless on
target-groups.

So either I assumed incorrectly how target-group was implemented, or
what you describe above (assuming depends attribute re-writing) is
incorrect. So which is it?

> In opposite,
> if you wanna execute explicitly "ant myTestTarget",  phase attribute is
> ignored (so skip.attribute should not be applied).

That makes perfect sense. --DD

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


Mime
View raw message