24

How can I determine the version of Ant coming with Eclipse?

T.Rob
  • 31,522
  • 9
  • 59
  • 103
user496949
  • 83,087
  • 147
  • 309
  • 426

4 Answers4

26

You can do so by typing the following command:

ant -version

Peter O.
  • 32,158
  • 14
  • 82
  • 96
Antonio Juarez
  • 261
  • 3
  • 2
18

Inside your ant script the ant.version property holds the information, if you need it programatically.

Thorbjørn Ravn Andersen
  • 73,784
  • 33
  • 194
  • 347
  • `ant.version` contains something like this: `Apache Ant(TM) version 1.9.6 compiled on June 29 2015` – trainmaster Mar 22 '18 at 16:55
  • However, there is Antversion task: https://ant.apache.org/manual/Tasks/antversion.html to get the version in parseable format. – trainmaster Mar 22 '18 at 17:12
14

In the About Eclipse -> Eclipse.org button -> Eclipse.org Plug-in Details you will see Apache Ant plugin with version information

enter image description here

TigrisC
  • 1,320
  • 9
  • 11
10

Although TigrisCs answer will give you the installed Ant bundle version, this version is not neccessarily the version you're executing your Ant files against. The dialog where you find the Ant version that is used to execute Ant files you'll find under Window->Preferences->Ant->Runtime

Ant runtime preferences

HTH Tom

Tom Seidel
  • 9,525
  • 1
  • 26
  • 38