Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Passing parameters to ant build script in Eclipse

 
Dave Alvarado
Ranch Hand
Posts: 436
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I'm using Eclipse 3.4 on Windows XP. When running an ant script, how do I pass in command line arguments, for example "-Denv=dev" like I would if I were running Ant through a shell script? I've tried setting an environment variable ...

http://screencast.com/t/PJiZQp0Wp

but my script is not picking that up. Any help is appreciated, - Dave
 
Tim Holloway
Saloon Keeper
Posts: 18304
56
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Right-Click on the build.xml file. Select "Ant Build...". This brings up a multi-tabbed Ant run dialog.

Set the Parameters using the Parameters textarea box on the Main tab. You can also add classpath items using this dialog if you need to.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic