jscripter schrieb am 22.06.2009 um 14:16:24 (-0700):

> >   <target name="deploy-using-copy" depends="trg1,trg3,trg5">
> >   ...
> > 
> >   <target name="deploy-using-link" depends="trg1,trg3,trg5">
> >   ...

> I need to preserve the execution order of the tasks, so I don't think
> that would work.

>From a recent post of David Weintraub:

| You say that B depends upon A, and C depends upon A and that A depends
| upon D, and both Ant and Make will calculate out the build order of
| your components. If you make a change (Say B now depends upon both A
| and C, Ant [...] will adjust the build without major rewriting of your
| build script.

This suggests you could guarantee execution order by setting up the
dependency matrix accordingly. Let your main tasks depend on trg5, which
in turn depends on trg3, which in turn depends on trg1.

Also, take a look at the manual, which has this example:

    <target name="A"/>
    <target name="B" depends="A"/>
    <target name="C" depends="B"/>
    <target name="D" depends="C,B,A"/>

        Suppose we want to execute target D. From its depends attribute, you
        might think that first target C, then B and then A is executed. Wrong!
        C depends on B, and B depends on A, so first A is executed, then B,
        then C, and finally D.

http://ant.apache.org/manual/using.html#targets

Michael Ludwig

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to