ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Adam Hardy <>
Subject Re: show list of available tasks
Date Sat, 13 Mar 2004 10:03:06 GMT
> --- Bill Rich <> wrote:
>>I think -p -v will yield a list of Major Tasks
>>(those tasks with a description) and Other
>>Tasks (those without a description).

There is another issue - perhaps an enhancement :) - to do with this 

ant -p only picks up the description attribute on the target.

   <target name="init" depends="init-common"
     description="Sets up the appserver properties and classpath">

When I was documenting my build file, like the good developer I am, my 
descriptions were always a little bit too verbose for one line, and my 
editor keeps wanting to wrap them, which is of course not XML.

So I tried this:

   <target name="init" depends="init-common">
       Sets up the appserver properties and classpath
       and have more than one line bla bla bla

and weird things happened. Ant -p missed it, and thought it must be a 
private target. But ant didn't miss it entirely, it spat out the 
description text at a random place in the output:

Buildfile: build.xml

       Sets up the appserver properties and classpath

Main targets:

  all                  Clean build and dist, then compile and deploy war
  assemble-ear         package all required Jars into EAR
  clean                delete old build and dist directories
  compile              Compile Java sources
  del-deploy           del deployed app from server
  del-deploy-tomcat-5  Delete tomcat-5 works deploy dir & context.xml
  deploy-ear           deploys an EAR file to appserver
  deploy-war           deploy app to server (or lib if no appserver)
  deploy-web           deploy app to server (or lib if no appserver)
  deploy-web-tomcat-5  places context.xml in conf/Catalina/localhost/
  ejb-jar              package class files into Jars
  init-common          Sets up the appserver properties and classpath
  jar                  jars up whatever it finds in build
  javadoc              Create Javadoc API documentation
  war                  Create war file
Default target: deploy

Bug, enhancement or other?
ant 1.6.0 + java 1.4.2 on Linux 2.4.20 Debian

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message