This week's book giveaway is in the Mac OS forum.
We're giving away four copies of a choice of "Take Control of Upgrading to Yosemite" or "Take Control of Automating Your Mac" and have Joe Kissell on-line!
See this thread for details.
The moose likes Ant, Maven and Other Build Tools and the fly likes ant not recognized... Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Bookmark "ant not recognized..." Watch "ant not recognized..." New topic
Author

ant not recognized...

Joey Doodle
Greenhorn

Joined: Aug 02, 2006
Posts: 2
Hi,

This is my first time trying to run ant and I get the message that "ant is not recognized as an internal or external command"

I know this has to do with my environment variables, but I'm not sure what I'm missing. Ant is installed on a server called bfdevbuild. Listed below are my environment variables and their values.

Does anyone see what I'm missing?

Thanks,
Matt

ANT_HOME
\\bfdevbuild\tools\ant

PATH
\\bfdevbuild\tools\ant\bin\;%ANT_HOME%\bin;%JAVA_HOME%/jre/bin;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;C:\Program Files\NetManage\Windows;C:\Program Files\Microsoft SQL Server\80\Tools\BINN;C:\Program Files\SQLLIB\BIN;C:\Program Files\SQLLIB\FUNCTION;C:\Program Files\SQLLIB\HELP;C:\Program Files\QuickTime\QTSystem\;C:\Program Files\Microsoft SQL Server\80\Tools\Binn\;C:\Program Files\Microsoft SQL Server\90\Tools\binn\;C:\Program Files\Microsoft SQL Server\90\DTS\Binn\;C:\Program Files\Microsoft SQL Server\90\Tools\Binn\VSShell\Common7\IDE\;C:\Program Files\Microsoft Visual Studio 8\Common7\IDE\PrivateAssemblies\;c:\j2sdk1.4.2_09\bin\

CLASSPATH
\\bfdevbuild\j2sdk1.4.2_09\lib\tools.jar;.;C:\Program Files\SQLLIB\java\db2java.zip;C:\Program Files\SQLLIB\java\runtime.zip;C:\Program Files\SQLLIB\java\sqlj.zip;C:\Program Files\SQLLIB\bin;C:\Program Files\Java\j2re1.4.2_09\lib\ext\QTJava.zip

JAVA_HOME
\\bfdevbuild\j2sdk1.4.2_09\
Ernest Friedman-Hill
author and iconoclast
Marshal

Joined: Jul 08, 2003
Posts: 24187
    
  34

Hi,

Welcome to JavaRanch!

The thing that's relevant to that message is the PATH, and that looks fine, if[/if] there's a file named \\bfdevbuild\tools\ant\bin\ant.bat accessible from your system. If there isn't, then find where ant.bat really is, and change the PATH to point to its exact directory.

If it [i]is
there, then perhaps you just need to close your terminal window and open a new one so it picks up these new environment variables.


[Jess in Action][AskingGoodQuestions]
 
GeeCON Prague 2014
 
subject: ant not recognized...