How do I make different antcalls depending upon the command line argument passed in to a certain target?
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Mark_Shearman
Posted On:   Wednesday, May 29, 2002 01:45 AM

I need to have some kind of condition that checks the value of an argument specified by "-Dmyprop=____" in the command line. Depending on which of the four possibilities are selected I would like to make different antcalls.


Mark

Re: How do I make different antcalls depending upon the command line argument passed in to a certain target?

Posted By:   Christian_Ey  
Posted On:   Wednesday, May 29, 2002 02:38 AM

Hi Mark,



you could do something like this:






























To select a target to be called, just run the build script
with an argument like -Dsecond=true or
-Dthird=true.



If you use Ant version 1.4 or newer, you can also use the
task, see the href="http://jakarta.apache.org/ant/faq.html#multi-conditions">Ant
FAQ
for an example.



Hope this helps,

Chris

About | Sitemap | Contact