diff --git a/docs/manual/targets.html b/docs/manual/targets.html index 40215cc46..447f990a0 100644 --- a/docs/manual/targets.html +++ b/docs/manual/targets.html @@ -52,6 +52,8 @@ 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.

+ +
Call-Graph:  A --> B --> C --> D

In a chain of dependencies stretching back from a given target such as D above, each target gets executed only once, even when @@ -109,6 +111,8 @@ </target> +

Call-Graph:  myTarget.check --> maybe(myTarget)
+

If no if and no unless attribute is present, the target will always be executed.

@@ -131,8 +135,25 @@ so-called initialization target, on which all other targets depend. Make sure that target is always the first one in the depends list of the other targets. In this manual, most - initialization targets have the - name "init".

+ initialization targets have the name "init".

+
+    <project>
+        <target name="init">
+            <tstamp/>
+        </target>
+        <target name="otherTarget" depends="init">
+            ...
+        </target>
+    </project>
+    
+ +

Especially if you only have a few tasks you also could place these + tasks direclty under the project tag (since Ant 1.6.0):

+
+    <project>
+        <tstamp/>
+    </project>
+    

If the depends attribute and the if/unless attribute are set, the depends attribute is executed first.

@@ -242,6 +263,9 @@ </target> +
Call-Graph:  create-directory-layout --> 'empty slot' --> compile
+ +

And you need to generate some source before compilation, then in your main build file you may use something like

@@ -251,6 +275,9 @@
 </target>
 
+
Call-Graph:  create-directory-layout --> generate-sources  --> compile
+ +

This will ensure that the generate-sources target is executed before the compile target.