How do I install ant on OS X Mavericks?

Solution 1:

It looks like the alternate repository was migrated. You can either enable the homebrew alternate repository or install directly after updating your brew:

brew update
brew install ant

Solution 2:

Upgraded to Mavericks this morning and found "command not found: ant"

brew update

Ran the the update and then tried to install ant.

brew install ant

Ant was installed, but it also yeilded this alert:

Warning: No developer tools installed. You should install the Command Line Tools. Run xcode-select --install to install them.

xcode-select --install

Now, everything is running fine.

Solution 3:

As an alternative to Homebrew, you can always download a binary distribution of Ant from http://ant.apache.org/bindownload.cgi. It works fine on OS X Mavericks.

Just download it, unzip/untar it, and add its bin directory to your PATH.

Solution 4:

The sequence that worked for me:

xcode-select --install
brew update
brew install ant

Solution 5:

I usually install ant via Homebrew. There is a pretty good documentation .

Good luck.