Command line Ant vs. in IDEA Ant

I have just starting using a trial copy of 3.0.4 (Build 701) and have had a world of trouble with my existing build script. Although the script works perfectly well at the command prompt (win2k sp3) it did not work in IDEA.

First it was the ]]> task. I ended up putting all the xdoclet jars into the /ant/lib dir. Then it was junit and the dreaded "Could not create task or type of type: junit." problem. Are these an IDEA problems? Not really, but IDEA isn't automatically grabbing the files in the /ant/lib dir.

Do yourself a favor. Open up your build script in IDEA, get the Ant Build Properties screen up and add every jar in the ant lib directory to the additional classpath tab there. That's as close to a silver bullet as you are going to get.

1 comment
Comment actions Permalink

Hi !

I use Ant both ways since the development team i have to support wants to use as much integrated in their IDE as possible otherwise some things need to be automated. And thats exactly what ant / IntelliJ supports ...

The only thing i would like that it would be possible to add a properties file to the ant-call not just Properties in the Settings tab of that build file.

I never had problems like you mentioned although we are also producing complex projects using xDoclet, RMI, ClearCase, Corba and others.

So you should not compare ... use both !! and if you encounter problems try to have the build file compatible for both kinds of usage.

0

Please sign in to leave a comment.