ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dominique Devienne <DDevie...@lgc.com>
Subject RE: init target
Date Fri, 30 Aug 2002 14:06:12 GMT
No. init used to be a 'magic' target I heard, but it was changed, and the
mindset is pretty much against magic targets... but don't worry, you'll soon
be able to put any task in the top-level (directly under <project> instead
of inside a <target>), so you'll have the same effect in a more natural way.
In the mean time, you can do:

    <target name="init"/>

    <target name="t1" depends="init"/>
    <target name="t2" depends="t1"/>
    <target name="t3" depends="t1"/>
    <target name="t4" depends="init"/>
    <target name="t5" depends="t1,t3"/>

and depend on the fact t1 depends on init, so any target depending on init
doesn't need to reference init directly. --DD

-----Original Message-----
From: Jochen Wiedmann [mailto:joe@ispsoft.de] 
Sent: Tuesday, August 27, 2002 2:35 AM
To: ant-user@jakarta.apache.org
Subject: init target


Hi,

when working with custom tasks, but also in general,
I frequently find myself doing things like this:

    <target name="init"/>

    <target name="t1" depends="init"/>
    <target name="t2" depends="init,t1"/>
    <target name="t3" depends="init,t1"/>
    <target name="t4" depends="init"/>
    <target name="t5" depends="init,t1,t3"/>
    ...


Is it possible to simplify this? A "magic" target?
More important, can I force other users to depend
on the "init" target?


Regards,

Jochen

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


Mime
View raw message