The moose likes Ant, Maven and Other Build Tools and the fly likes Is it possible -- Calling ant user defined parameter? Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of Practical Unit Testing with TestNG and Mockito this week in the Testing forum!
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Reply Bookmark "Is it possible -- Calling ant user defined parameter?" Watch "Is it possible -- Calling ant user defined parameter?" New topic
Author

Is it possible -- Calling ant user defined parameter?

Ayse Muge
Greenhorn

Joined: Jul 22, 2004
Posts: 5
Is it possible that the using ant with some user defined parameter?

For example, I wanna give my StarTeam version control system build label as a parameter and then corresponding target can use this parameter in stcheckout task for its label attribute.
My build label is build1001 and then I wanna use it in command line as follows:

ant build1001

'build1001' pass as parameter to stcheckout label attribute.

Is it possible? I can't find the way...
Kalai Selvan
Ranch Hand

Joined: Jul 07, 2004
Posts: 79
Hi Ayse,

I am not too sure about passing parameter to ant, but i think you can use input task of ant. I hope it will solve your purpose.


Kalai Selvan T.
Ayse Muge
Greenhorn

Joined: Jul 22, 2004
Posts: 5
Thank you Kalai
Bear Bibeault
Author and opinionated walrus
Marshal

Joined: Jan 10, 2002
Posts: 50675

Check out using the -D option on the command line.


[Smart Questions] [JSP FAQ] [Books by Bear] [Bear's FrontMan] [About Bear]
 
 
subject: Is it possible -- Calling ant user defined parameter?
 
Threads others viewed
How to get value of Application Build Level (i.e. Implementation-Version) in JSP
Ant build qn
how to make a .war file
Ant does not output property file in classes folder.
Weblogic webservice failing for user defined types
IntelliJ Java IDE