Is there a property that holds the current target?  In make, $@ contains the target 
you're building.  "Built-in Properties" in 
http://jakarta.apache.org/ant/manual/using.html indicates there isn't an ant 
equivalent.

It would be somewhat useful to know the current target in commands within a target.  
For example, in

<target name="dreamweaver" depends="init" >
        <!-- "dreamweaver" below is the same as target name -->
        <mkdir dir="products/dreamweaver"/>
        <!-- ... more tasks containing the string "dreamweaver" -->
</target>

<!-- same rules as above -->
<target name="flash" depends="init" >
        <!-- "flash" below is the same as target name -->
        <mkdir dir="products/flash"/>
        <!-- ... more tasks containing the string "flash" -->
</target>

I'd like to use <mkdir dir="products/${ant.current_target}"/>  so similar tasks have 
the same code.


Or am I not grokking the ant philosophy?  Should I instead write a generic task, and 
use antcall to call it with different parameters?  Or should I write a custom mapper 
that fabricates targets for a given file?  Or... ?  If the documentation contained 
snippets of build files that show ant features working together, it would be more 
obvious.

Thanks indeed.
-- 
=S Page  a www.macromedia.com site engineer 

Reply via email to