ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 4025] New: - help attribute on target
Date Mon, 08 Oct 2001 18:53:58 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=4025>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=4025

help attribute on target

           Summary: help attribute on target
           Product: Ant
           Version: 1.1
          Platform: All
        OS/Version: Other
            Status: NEW
          Severity: Enhancement
          Priority: Other
         Component: Core
        AssignedTo: ant-dev@jakarta.apache.org
        ReportedBy: doug_whitehead@yahoo.com


add an attribute to the "target" tag called "help", that will allow a new 
default target of "ant help" to print out all targets available that have 
defined with the help attribute.  In this way, one can keep the comments for a 
given target with the target itself, and not in a separate help target, and the 
comments can be used for both build.xml documentation (instead of <!-- comment 
-->) and at run time to discover targets defined.

For example,

<target name="build" help="Compile source files">....</target>
<target name="install" help="Install ejbs into weblogic">...</target>

and if one were to type:

ant help

ant would respond:

build -   Compile source files
install -    Install ejbs into weblogic

This is especially useful if one is using an XML include to share a template.  
Some of the targets will be defined in the shared template, others will be 
defined in the build.xml of the directory.  In this way, the comments of all 
targets, both shared and local, will be reported when "ant help" is executed.

Mime
View raw message