git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@269494 13f79535-47bb-0310-9956-ffa450edef68master
@@ -0,0 +1,101 @@ | |||
<?xml version="1.0"?> | |||
<document> | |||
<properties> | |||
<author email="conor@cortexebusiness.com.au">Conor MacNeill</author> | |||
<author email="stefan.bodewig@epost.de">Stefan Bodewig</author> | |||
<title>Ant News</title> | |||
</properties> | |||
<body> | |||
<section name="Ant Needs a Logo"> | |||
<p>Ant still doesn't have a Logo, but it sure deserves one. We've | |||
put together a <a href="logos.html">page with proposed | |||
logos</a>, please take a look at them and tell us what you | |||
think. If you have a nice logo idea yourself, just submit it to | |||
the mailing lists.</p> | |||
</section> | |||
<section name="Ant 2.0 Requirements Collected - Next is Design"> | |||
<p>A commented version of the collected user requirements is now | |||
available <a href="/ant/ant2/features.html">here</a> - it is not | |||
complete as some details still have to be defined, but it should | |||
give you an idea of what Ant2 is going to look like.</p> | |||
<p>Several details can only be decided in the light of real code | |||
and prototypes. Several people are working on prototypes (that | |||
can be found in Ant's CVS module in the proposals directory) and | |||
discussion is going on on the Ant-Dev mailing list.</p> | |||
</section> | |||
<section name="Best-Practices Profile of Ant at Sun's Dot-Com Builder"> | |||
<p>Sun has released an introductory article on Ant on their | |||
Dot-Com Builder site on May 30 2001. See <a | |||
href="http://dcb.sun.com/practices/profiles/ant.jsp">http://dcb.sun.com/practices/profiles/ant.jsp</a></p> | |||
</section> | |||
<section name="Ant 2.0 Requirements"> | |||
<p>Ant has been in use for quite some time and has been used in ways never conceived when it | |||
was originally written. While Ant 1.x has continued to sucessfully evolve and grow, there | |||
are a number of limitations and inconsistencies that are now apparent and which need to | |||
be addressed. | |||
</p> | |||
<p> | |||
As we continue to evolve and enhance Ant 1.x, it is now time to define what Ant 2.0 will | |||
encompass. Ant 2.0 will be a major rearchitecting of Ant. It has a number of goals including: | |||
<ul> | |||
<li>Define the "contract" with build file writers to which Ant will be bound.</li> | |||
<li>Define the "contract" between the Ant core and Task writers.</li> | |||
<li>Make Ant more easily extendable by allowing additional tasks to be "dropped" in.</li> | |||
<li>Allow Ant to function as a component to simplify integration with GUIs and IDEs.</li> | |||
<li>Make Ant more regular and logical.</li> | |||
</ul> | |||
It is expected that Ant 2.0 will break Ant 1.x based build files. The intention is to | |||
make this the last time that will happen. | |||
</p> | |||
<p> | |||
To advance the definition of Ant, user requirements are now being accepted on the | |||
Ant-Dev mailing list. Any requirement will be accepted for consideration. The | |||
requirements are being collected into a document which is available | |||
<a href="/ant/ant2/requested-features.txt">on-line</a>. New features will be excepted | |||
until March 21st, 2001. At that time, each requirement will be discussed | |||
for inclusion in an Ant 2.0 requirement document. | |||
</p> | |||
<p> | |||
For your reference some of the goals which have shaped the development of Ant 1.x are | |||
available <a href="/ant/ant2/original-specification.html">here</a>. These continue to be | |||
relevant to Ant 2.0. | |||
</p> | |||
<p> | |||
If you want to shape the future of Ant, join the | |||
<a href="/site/mail.html">Ant-Dev mailing list</a> and contribute | |||
your ideas. | |||
</p> | |||
</section> | |||
<section name="Ant 1.3 Released"> | |||
<p> | |||
Ant 1.3 has been released after going through three betas. Thanks to everyone who | |||
took the time to test the beta and report bugs and enhancements. | |||
</p> | |||
<p>You can download the release from | |||
<a href="http://jakarta.apache.org/builds/jakarta-ant/release/v1.3/">here</a>. | |||
Both source and binary releases are available in zip, tarball and RPM formats. | |||
</p> | |||
<p>Please report all bugs using the | |||
<a href="http://nagoya.apache.org/bugzilla/enter_bug.cgi?product=Ant">Apache Bugzilla</a> | |||
</p> | |||
</section> | |||
</body> | |||
</document> | |||
@@ -0,0 +1,351 @@ | |||
<?xml version="1.0"?> | |||
<document> | |||
<properties> | |||
<author email="bodewig@apache.org">Stefan Bodewig</author> | |||
<title>External Tools and Tasks</title> | |||
</properties> | |||
<body> | |||
<section name="External Tools and Tasks"> | |||
<p>This page lists external resources for Ant: tasks, IDE | |||
integration tools, loggers, you name it. If you've written | |||
something that should be included, please post all relevant | |||
information to one of the mailing lists.</p> | |||
<p>Nothing listed here is directly supported by the Ant | |||
developers, if you encounter any problems with them, please use | |||
the contact information.</p> | |||
</section> | |||
<section name="Tasks"> | |||
<subsection name="AJC"> | |||
<p><a href="http://aspectj.org">AspectJ</a> is an | |||
aspect-oriented extension to Java. This task compiles a | |||
source tree using the AspectJ compiler -- AJC.</p> | |||
<table> | |||
<tr> | |||
<th>Compatibility:</th> | |||
<td>Ant 1.3</td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://aspectj.org/dl">http://aspectj.org/dl</a></td> | |||
</tr> | |||
<tr> | |||
<th>Contact:</th> | |||
<td><a href="mailto:support@aspectj.org">support@aspectj.org</a></td> | |||
</tr> | |||
<tr> | |||
<th>License:</th> | |||
<td>Apache Software License</td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="Anakia"> | |||
<p>Actually, Anakia is more than just an Ant task, it is a an | |||
XML transformation tool based on JDOM, Velocity and Ant.</p> | |||
<table> | |||
<tr> | |||
<th>Compatibility:</th> | |||
<td>Ant 1.2 and 1.3</td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://jakarta.apache.org/velocity/anakia.html">http://jakarta.apache.org/velocity/anakia.html</a></td> | |||
</tr> | |||
<tr> | |||
<th>Contact:</th> | |||
<td><a href="http://jakarta.apache.org/site/mail2.html">Velocity mailing lists</a></td> | |||
</tr> | |||
<tr> | |||
<th>License:</th> | |||
<td>Apache Software License</td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="Checkstyle"> | |||
<p>Checkstyle is a development tool to help programmers write | |||
Java code that adheres to a coding standard. Its purpose is to | |||
automate the process of checking Java code, and to spare | |||
humans of this boring (but important) task.</p> | |||
<p>Checkstyle can be run via an ANT task or a command line | |||
utility.</p> | |||
<table> | |||
<tr> | |||
<th>Compatibility:</th> | |||
<td>Ant 1.2 and 1.3</td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://www.puppycrawl.com/checkstyle">http://www.puppycrawl.com/checkstyle</a></td> | |||
</tr> | |||
<tr> | |||
<th>Contact:</th> | |||
<td><a href="mailto:checkstyle@puppycrawl.com">Oliver Burn</a></td> | |||
</tr> | |||
<tr> | |||
<th>License:</th> | |||
<td>GNU General Public License</td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="Configure"> | |||
<p>Recursive build support (call ant on every package level, | |||
and only build files in that package or in that package and | |||
everything below) with seperation of source and output.</p> | |||
<p>The task generates build files in any subdirectory (except | |||
for CVS-directories) for you. Only place one build.xml file in | |||
the top and call target 'setup' or | |||
'rescan'.</p> | |||
<table> | |||
<tr> | |||
<th>Compatibility:</th> | |||
<td>Ant 1.2 and 1.3</td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://www.dsdelft.nl/~lemval/ant/">http://www.dsdelft.nl/~lemval/ant/</a></td> | |||
</tr> | |||
<tr> | |||
<th>Contact:</th> | |||
<td><a href="mailto:lemval@dsdelft.nl">M.J.P. van Leeuwen</a></td> | |||
</tr> | |||
<tr> | |||
<th>License:</th> | |||
<td>License derived from Apache Software License</td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="J2ME Ant Tasks"> | |||
<p>There are two different sets of tasks to help build <a | |||
href="http://java.sun.com/j2me/">Java 2 Platform, Micro | |||
Edition</a> (J2ME) applications.</p> | |||
<p>This set supports CLDC and the K Virtual Machine (KVM):</p> | |||
<table> | |||
<tr> | |||
<th>Compatibility:</th> | |||
<td>Ant 1.3</td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://www.dribin.org/dave/j2me_ant/">http://www.dribin.org/dave/j2me_ant/</a></td> | |||
</tr> | |||
<tr> | |||
<th>Contact:</th> | |||
<td><a href="mailto:drib@enteract.com">Dave Dribin</a></td> | |||
</tr> | |||
<tr> | |||
<th>License:</th> | |||
<td>Apache Software License</td> | |||
</tr> | |||
</table> | |||
<p>And this set works with the J2ME Wireless Toolkit and MIDP | |||
for PalmOS:</p> | |||
<table> | |||
<tr> | |||
<th>Compatibility:</th> | |||
<td>Ant 1.3</td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://www.stampysoft.com/ant/">http://www.stampysoft.com/ant/</a></td> | |||
</tr> | |||
<tr> | |||
<th>Contact:</th> | |||
<td><a href="mailto:jeckels@stampysoft.com">Josh Eckels</a></td> | |||
</tr> | |||
<tr> | |||
<th>License:</th> | |||
<td>MIT License</td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="TiniAnt"> | |||
<p>TiniAnt is an Ant task to support building applications for | |||
the <a href="http://www.ibutton.com/TINI/">TINI</a>.</p> | |||
<table> | |||
<tr> | |||
<th>Compatibility:</th> | |||
<td>Ant 1.2 and 1.3</td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://tiniant.sourceforge.net/">http://tiniant.sourceforge.net/</a></td> | |||
</tr> | |||
<tr> | |||
<th>Contact:</th> | |||
<td><a href="mailto:kelly@ad1440.net">Sean Kelly</a></td> | |||
</tr> | |||
<tr> | |||
<th>License:</th> | |||
<td>BSD-like license</td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="Venus Application Publisher's (Vamp) Ant Task Suite"> | |||
<p>Venus Application Publisher's (Vamp) Ant Task Suite allows | |||
you to sign and package your applications into relocatable Web | |||
Archives that you can drop into your web server for | |||
single-click launching using Java Web Start or into single | |||
Java Archive installers that serve up their content through a | |||
built-in, multi-threaded, ultra light-weight web server.</p> | |||
<table> | |||
<tr> | |||
<th>Compatibility:</th> | |||
<td>Ant 1.2 and 1.3</td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://www.geocities.com/vamp201/ant.html">http://www.geocities.com/vamp201/ant.html</a></td> | |||
</tr> | |||
<tr> | |||
<th>Contact:</th> | |||
<td><a href="mailto:vamp201@yahoo.com">Gerald Bauer</a></td> | |||
</tr> | |||
<tr> | |||
<th>License:</th> | |||
<td>GNU General Public License</td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
</section> | |||
<section name="IDE/Editor Integration"> | |||
<subsection name="AntRunner"> | |||
<p>An OpenTool that integrates Ant into the JBuilder IDE.</p> | |||
<table> | |||
<tr> | |||
<th>Compatibility:</th> | |||
<td>Ant 1.2 and 1.3</td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://www.dieter-bogdoll.de/java/AntRunner/">http://www.dieter-bogdoll.de/java/AntRunner/</a></td> | |||
</tr> | |||
<tr> | |||
<th>Contact:</th> | |||
<td><a href="mailto:bogdoll@users.sourceforge.net">Dieter Bogdoll</a></td> | |||
</tr> | |||
<tr> | |||
<th>License:</th> | |||
<td>GNU General Public License</td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="AntWork"> | |||
<p>A plugin that integrates Ant into the Jext editor.</p> | |||
<table> | |||
<tr> | |||
<th>Compatibility:</th> | |||
<td>Ant 1.2 and 1.3</td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="ftp://jext.sourceforge.net/pub/jext/plugins/AntWork.zip">ftp://jext.sourceforge.net/pub/jext/plugins/AntWork.zip</a></td> | |||
</tr> | |||
<tr> | |||
<th>Contact:</th> | |||
<td><a href="mailto:KHartlage@t-online.de">Klaus Hartlage</a></td> | |||
</tr> | |||
<tr> | |||
<th>License:</th> | |||
<td>GNU General Public License</td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="NetBeans / Forte for Java"> | |||
<p>A module that integrates Ant into the NetBeans or Forte for Java IDEs.</p> | |||
<table> | |||
<tr> | |||
<th>Compatibility:</th> | |||
<td>bundles Ant 1.3</td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://ant.netbeans.org/">http://ant.netbeans.org/</a></td> | |||
</tr> | |||
<tr> | |||
<th>Contact:</th> | |||
<td><a href="mailto:nbdev@netbeans.org">nbdev@netbeans.org</a></td> | |||
</tr> | |||
<tr> | |||
<th>License:</th> | |||
<td>Sun Public License</td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
</section> | |||
<section name="Other"> | |||
<subsection name="CruiseControl"> | |||
<p>CruiseControl is a tool for setting up a continuous build | |||
process. CruiseControl provides an Ant wrapper and a set of | |||
tasks to automate the checkout/build/test cycle. CruiseControl | |||
also comes bundled with a servlet for viewing the status of | |||
the current build, as well as previous build results.</p> | |||
<table> | |||
<tr> | |||
<th>Compatibility:</th> | |||
<td>Ant 1.2 and 1.3</td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://cruisecontrol.sourceforge.net/">http://cruisecontrol.sourceforge.net/</a></td> | |||
</tr> | |||
<tr> | |||
<th>Contact:</th> | |||
<td><a href ='http://cruisecontrol.sourceforge.net/contact.html'>Project Mailing Lists and Administrators</a></td> | |||
</tr> | |||
<tr> | |||
<th>License:</th> | |||
<td>Release 1.0 has been licensed under the GNU General Public | |||
License. Starting with release 1.1 the license has been | |||
changed to a BSD-like license.</td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
</section> | |||
</body> | |||
</document> |
@@ -0,0 +1,581 @@ | |||
<?xml version="1.0"?> | |||
<document> | |||
<properties> | |||
<author email="bodewig@apache.org">Stefan Bodewig</author> | |||
<title>Frequently Asked Questions</title> | |||
</properties> | |||
<faqsection title="General"> | |||
<faq id="what-is-ant"> | |||
<question>What is Ant?</question> | |||
<answer> | |||
<p> Ant is a Java based build tool. In theory it is kind of | |||
like "make" without makes wrinkles and with the full | |||
portability of pure Java code.</p> | |||
</answer> | |||
</faq> | |||
<faq id="ant-name"> | |||
<question>Why do you call it Ant?</question> | |||
<answer> | |||
<p>According to Ant's original author James Duncan | |||
Davidson, the name is an acronym for "Another Neat | |||
Tool".</p> | |||
<p>Later explanations go along the lines of "Ants are | |||
doing an extremely good job at building things" or | |||
"Ants are very small and can carry a weight a dozen times | |||
of their own" - describing what Ant is intended to | |||
be.</p> | |||
</answer> | |||
</faq> | |||
<faq id="history"> | |||
<question>Tell us a little bit about Ant's history.</question> | |||
<answer> | |||
<p>Initially Ant was part of the Tomcat code base when it was | |||
donated to the Apache Software Foundation - it has been | |||
created by James Duncan Davidson, who also is the original | |||
author of Tomcat. Ant was there to build Tomcat, nothing | |||
else.</p> | |||
<p>Soon thereafter several open source Java projects realized | |||
that Ant could solve the problems they had with makefiles. | |||
Starting with the projects hosted at Jakarta and the old Java | |||
Apache project, Ant spread like a virus and now is the build | |||
tool of choice for a lot of projects.</p> | |||
<p>In January 2000 Ant was moved to a separate CVS module and | |||
was promoted to a project of its own, independent of | |||
Tomcat.</p> | |||
<p>The first version of Ant that was exposed a lager audience | |||
was the one that shipped with Tomcat's 3.1 release on 19 April | |||
2000. This version has later been referenced to as Ant | |||
0.3.1.</p> | |||
<p>The first official release of Ant as a stand alone product was | |||
Ant 1.1 released on 19 July 2000. The complete release | |||
history:</p> | |||
<table> | |||
<tr> | |||
<th>Ant Version</th> | |||
<th>Release Date</th> | |||
</tr> | |||
<tr> | |||
<td>1.1</td> | |||
<td>19 July 2000</td> | |||
</tr> | |||
<tr> | |||
<td>1.2</td> | |||
<td>24 October 2000</td> | |||
</tr> | |||
<tr> | |||
<td>1.3</td> | |||
<td>3 March 2001</td> | |||
</tr> | |||
</table> | |||
</answer> | |||
</faq> | |||
</faqsection> | |||
<faqsection title="Installation"> | |||
<faq id="no-gnu-tar"> | |||
<question>I get checksum errors when I try to extract the | |||
<code>tar.gz</code> distribution file. Why?</question> | |||
<answer> | |||
<p>Ant's distribution contains file names that are longer | |||
than 100 characters, which is not supported by the standard | |||
tar file format. Several different implementations of tar use | |||
different and incompatible ways to work around this | |||
restriction.</p> | |||
<p>Ant's <tar> task can create tar archives that use | |||
the GNU tar extension, and this has been used when putting | |||
together the distribution. If you are using a different | |||
version of tar (for example, the one shipping with Solaris), | |||
you cannot use it to extract the archive.</p> | |||
<p>The solution is to either install GNU tar, which can be | |||
found <a href="http://www.gnu.org/software/tar/tar.html">here</a> | |||
or use the zip archive instead (you can extract it using | |||
<code>jar xf</code>).</p> | |||
</answer> | |||
</faq> | |||
</faqsection> | |||
<faqsection title="Using Ant"> | |||
<faq id="always-recompiles"> | |||
<question>Why does Ant always recompile all my Java files?</question> | |||
<answer> | |||
<p>In order to find out which files should be compiled, Ant | |||
compares the timestamps of the source files to those of the | |||
resulting <code>.class</code> files. Opening all source files | |||
to find out which package they belong to would be very | |||
inefficient - instead of this, Ant expects you to place your | |||
source files in a directory hierarchy that mirrors your | |||
package hierarchy and to point Ant to the root of this | |||
directory tree with the <code>srcdir</code> attribute.</p> | |||
<p>Say you have <code><javac srcdir="src" | |||
destdir="dest" /></code>. If Ant finds a file | |||
<code>src/a/b/C.java</code> it expects it to be in package | |||
<code>a.b</code> so that the resulting <code>.class</code> | |||
file is going to be <code>dest/a/b/C.class</code>.</p> | |||
<p>If your setup is different, Ant's heuristic won't work and | |||
it will recompile classes that are up to date. Ant is not the | |||
only tool, that expects a source tree layout like this.</p> | |||
</answer> | |||
</faq> | |||
<faq id="passing-cli-args"> | |||
<question>How do I pass parameters from the command line to my | |||
build file?</question> | |||
<answer> | |||
<p>Use properties: <code>ant | |||
-D<name>=<value></code> lets you define values for | |||
properties. These can then be used within your build file as | |||
any normal property: <code>${<name>}</code> will put in | |||
<code><value></code>.</p> | |||
</answer> | |||
</faq> | |||
<faq id="jikes-switches"> | |||
<question>How can I use Jikes specific command line | |||
switches?</question> | |||
<answer> | |||
<p>A couple of switches are supported via magic | |||
properties:</p> | |||
<table> | |||
<tr> | |||
<th>switch</th> | |||
<th>property</th> | |||
<th>default</th> | |||
</tr> | |||
<tr> | |||
<td>+E</td> | |||
<td>build.compiler.emacs</td> | |||
<td>false == not set</td> | |||
</tr> | |||
<tr> | |||
<td>-nowarn</td> | |||
<td>build.compiler.warnings</td> | |||
<td>true == not set</td> | |||
</tr> | |||
<tr> | |||
<td>+P</td> | |||
<td>build.compiler.pedantic</td> | |||
<td>false == not set</td> | |||
</tr> | |||
<tr> | |||
<td>+F</td> | |||
<td>build.compiler.fulldepend</td> | |||
<td>false == not set</td> | |||
</tr> | |||
</table> | |||
</answer> | |||
</faq> | |||
<faq id="shell-redirect-1"> | |||
<question>How do I include a < character in my command line arguments?</question> | |||
<answer> | |||
<p>The short answer is "Use <code>&lt;</code>".</p> | |||
<p>The long answer is, that this probably won't do what you | |||
want anyway, see <a href="#shell-redirect-2">the next | |||
section</a>.</p> | |||
</answer> | |||
</faq> | |||
<faq id="shell-redirect-2"> | |||
<question>How do I redirect standard input or standard output | |||
in the <code><exec></code> task?</question> | |||
<answer> | |||
<p>Say you want to redirect the standard input stream of the | |||
<code>cat</code> command to read from a file, something | |||
like</p> | |||
<source><![CDATA[ | |||
shell-prompt> cat < foo | |||
]]></source> | |||
<p>and try to translate it into</p> | |||
<source><![CDATA[ | |||
<exec executable="cat"> | |||
<arg value="<" /> | |||
<arg value="foo" /> | |||
</exec> | |||
]]></source> | |||
<p>This will not do what you expect. The input-redirection is | |||
performed by your shell, not the command itself, so this | |||
should read:</p> | |||
<source><![CDATA[ | |||
<exec executable="/bin/sh"> | |||
<arg value="-c" /> | |||
<arg value="cat < foo" /> | |||
</exec> | |||
]]></source> | |||
<p>Note, that you must use the <code>value</code> attribute of | |||
<code><arg></code> in the last element.</p> | |||
</answer> | |||
</faq> | |||
</faqsection> | |||
<faqsection title="Ant and IDEs/Editors"> | |||
<faq id="integration"> | |||
<question>Is Ant supported by my IDE/Editor?</question> | |||
<answer> | |||
<p>See the <a href="external.html#IDE%47Editor+Integration">section | |||
on IDE integration</a> on our external tools page.</p> | |||
</answer> | |||
</faq> | |||
<faq id="emacs-mode"> | |||
<question>Why doesn't (X)Emacs/vi/MacOS X's project builder | |||
parse the error messages generated by Ant correctly?</question> | |||
<answer> | |||
<p>Ant adds a "banner" with the name of the current | |||
task in front of all messages - and there are no built-in | |||
regular expressions in your Editor that would account for | |||
this.</p> | |||
<p>You can disable this banner by invoking Ant with the | |||
<code>-emacs</code> switch. Alternatively you can add the | |||
following snippet to your <code>.emacs</code> to make Emacs | |||
understand Ant's output.</p> | |||
<source><![CDATA[ | |||
(require 'compile) | |||
(setq compilation-error-regexp-alist | |||
(append (list | |||
;; works for jikes | |||
'("^\\s-*\\[[^]]*\\]\\s-*\\(.+\\):\\([0-9]+\\):\\([0-9]+\\):[0-9]+:[0-9]+:" 1 2 3) | |||
;; works for javac | |||
'("^\\s-*\\[[^]]*\\]\\s-*\\(.+\\):\\([0-9]+\\):" 1 2)) | |||
compilation-error-regexp-alist)) | |||
]]></source> | |||
<p>Yet another alternative that preserves most of Ant's | |||
formatting is to pipe Ant's output through the following Perl | |||
script by Dirk-Willem van Gulik:</p> | |||
<source><![CDATA[ | |||
#!/usr/bin/perl | |||
# | |||
# May 2001 dirkx@apache.org - remove any | |||
# [foo] lines from the output; keeping | |||
# spacing more or less there. | |||
# | |||
$|=1; | |||
while(<STDIN>) { | |||
if (s/^(\s+)\[(\w+)\]//) { | |||
if ($2 ne $last) { | |||
print "$1\[$2\]"; | |||
$s = ' ' x length($2); | |||
} else { | |||
print "$1 $s "; | |||
}; | |||
$last = $2; | |||
}; | |||
print; | |||
}; | |||
]]></source> | |||
</answer> | |||
</faq> | |||
</faqsection> | |||
<faqsection title="Advanced issues"> | |||
<faq id="dtd"> | |||
<question>Is there a DTD that I can use to validate my build | |||
files?</question> | |||
<answer> | |||
<p>An incomplete DTD can be created by the | |||
<code><antstructure></code> task - but this one | |||
has a few problems:</p> | |||
<ul> | |||
<li>It doesn't know about required attributes. Only | |||
manual tweaking of this file can help here.</li> | |||
<li>It is not complete - if you add new tasks via | |||
<code><taskdef></code> it won't know about it. See | |||
<a href="http://www.sdv.fr/pages/casa/html/ant-dtd.en.html">this | |||
page</a> by Michel Casabianca for a solution to this | |||
problem. Note that the DTD you can download at this page | |||
is based on Ant 0.3.1.</li> | |||
<li>It may even be an invalid DTD. As Ant allows tasks | |||
writers to define arbitrary elements, name collisions will | |||
happen quite frequently - if your version of Ant contains | |||
the optional <code><test></code> and | |||
<code><junit></code> tasks, there are two XML | |||
elements named test (the task and the nested child element | |||
of <code><junit></code>) with different attribute | |||
lists. This problem cannot be solved, DTDs don't give a | |||
syntax rich enough to support this.</li> | |||
</ul> | |||
</answer> | |||
</faq> | |||
<faq id="xml-entity-include"> | |||
<question>How do I include an XML snippet in my build file?</question> | |||
<answer> | |||
<p>You can use XML's way of including external files and let | |||
the parser do the job for Ant:</p> | |||
<source><![CDATA[ | |||
<?xml version="1.0"?> | |||
<!DOCTYPE project [ | |||
<!ENTITY common SYSTEM "file:./common.xml"> | |||
]> | |||
<project name="test" default="test" basedir="."> | |||
<target name="setup"> | |||
... | |||
</target> | |||
&common; | |||
... | |||
</project> | |||
]]></source> | |||
<p>will literally include the contents of <code>common.xml</code> where | |||
you've placed the <code>&common;</code> entity.</p> | |||
<p>In combination with a DTD, this would look like this:</p> | |||
<source><![CDATA[ | |||
<!DOCTYPE project PUBLIC "-//ANT//DTD project//EN" "file:./ant.dtd" [ | |||
<!ENTITY include SYSTEM "file:./header.xml"> | |||
]> | |||
]]></source> | |||
</answer> | |||
</faq> | |||
<faq id="mail-logger"> | |||
<question>How do I send an email with the result of my build | |||
process?</question> | |||
<answer> | |||
<p>You can use a custom BuildListener, that sends out an email | |||
in the buildFinished() method. Will Glozer | |||
<will.glozer@jda.com> has written such a listener based | |||
on <a href="http://java.sun.com/products/javamail/">JavaMail</a>, | |||
the source is</p> | |||
<source><![CDATA[ | |||
import java.io.*; | |||
import java.util.*; | |||
import javax.mail.*; | |||
import javax.mail.internet.*; | |||
import org.apache.tools.ant.*; | |||
/** | |||
* A simple listener that waits for a build to finish and sends an email | |||
* of the results. The settings are stored in "monitor.properties" and | |||
* are fairly self explanatory. | |||
* | |||
* @author Will Glozer | |||
* @version 1.05a 09/06/2000 | |||
*/ | |||
public class BuildMonitor implements BuildListener { | |||
protected Properties props; | |||
/** | |||
* Create a new BuildMonitor. | |||
*/ | |||
public BuildMonitor() throws Exception { | |||
props = new Properties(); | |||
InputStream is = getClass().getResourceAsStream("monitor.properties"); | |||
props.load(is); | |||
is.close(); | |||
} | |||
public void buildStarted(BuildEvent e) { | |||
} | |||
/** | |||
* Determine the status of the build and the actions to follow, now that | |||
* the build has completed. | |||
* | |||
* @param e Event describing the build tatus. | |||
*/ | |||
public void buildFinished(BuildEvent e) { | |||
Throwable th = e.getException(); | |||
String status = (th != null) ? "failed" : "succeeded"; | |||
try { | |||
String key = "build." + status; | |||
if (props.getProperty(key + ".notify").equalsIgnoreCase("false")) { | |||
return; | |||
} | |||
Session session = Session.getDefaultInstance(props, null); | |||
MimeMessage message = new MimeMessage(session); | |||
message.addRecipients(Message.RecipientType.TO, parseAddresses( | |||
props.getProperty(key + ".email.to"))); | |||
message.setSubject(props.getProperty(key + ".email.subject")); | |||
BufferedReader br = new BufferedReader(new FileReader( | |||
props.getProperty("build.log"))); | |||
StringWriter sw = new StringWriter(); | |||
String line = br.readLine(); | |||
while (line != null) { | |||
sw.write(line); | |||
sw.write("\n"); | |||
line = br.readLine(); | |||
} | |||
br.close(); | |||
message.setText(sw.toString(), "UTF-8"); | |||
sw.close(); | |||
Transport transport = session.getTransport(); | |||
transport.connect(); | |||
transport.send(message); | |||
transport.close(); | |||
} catch (Exception ex) { | |||
System.out.println("BuildMonitor failed to send email!"); | |||
ex.printStackTrace(); | |||
} | |||
} | |||
/** | |||
* Parse a comma separated list of internet email addresses. | |||
* | |||
* @param s The list of addresses. | |||
* @return Array of Addresses. | |||
*/ | |||
protected Address[] parseAddresses(String s) throws Exception { | |||
StringTokenizer st = new StringTokenizer(s, ","); | |||
Address[] addrs = new Address[st.countTokens()]; | |||
for (int i = 0; i < addrs.length; i++) { | |||
addrs[i] = new InternetAddress(st.nextToken()); | |||
} | |||
return addrs; | |||
} | |||
public void messageLogged(BuildEvent e) { | |||
} | |||
public void targetStarted(BuildEvent e) { | |||
} | |||
public void targetFinished(BuildEvent e) { | |||
} | |||
public void taskStarted(BuildEvent e) { | |||
} | |||
public void taskFinished(BuildEvent e) { | |||
} | |||
} | |||
]]></source> | |||
<p>With a <code>monitor.properties</code> like this</p> | |||
<source><![CDATA[ | |||
# configuration for build monitor | |||
mail.transport.protocol=smtp | |||
mail.smtp.host=<host> | |||
mail.from=Will Glozer <will.glozer@jda.com> | |||
build.log=build.log | |||
build.failed.notify=true | |||
build.failed.email.to=will.glozer@jda.com | |||
build.failed.email.subject=Nightly build failed! | |||
build.succeeded.notify=true | |||
build.succeeded.email.to=will.glozer@jda.com | |||
build.succeeded.email.subject=Nightly build succeeded! | |||
]]></source> | |||
<p><code>monitor.properties</code> should be placed right next | |||
to your compiled <code>BuildMonitor.class</code>. To use it, | |||
invoke Ant like</p> | |||
<source><![CDATA[ | |||
ant -listener BuildMonitor | |||
]]></source> | |||
<p>Make sure that <code>mail.jar</code> from JavaMail and | |||
<code>activation.jar</code> from the | |||
<a href="http://java.sun.com/products/javabeans/glasgow/jaf.html">Java | |||
Beans Activation Framework</a> in your <code>CLASSPATH</code>.</p> | |||
</answer> | |||
</faq> | |||
</faqsection> | |||
<faqsection title="Known problems"> | |||
<faq id="remove-cr"> | |||
<question><chmod> or <exec> don't work in Ant | |||
1.3 on Unix</question> | |||
<answer> | |||
<p>The <code>antRun</code> script in <code>ANT_HOME/bin</code> | |||
has DOS instead of Unix line endings, you must remove the | |||
carriage return characters from this file. This can be done by | |||
using Ant's <fixcrlf> task or something like:</p> | |||
<source><![CDATA[ | |||
tr -d '\r' < $ANT_HOME/bin/antRun > /tmp/foo | |||
mv /tmp/foo $ANT_HOME/bin/antRun | |||
]]></source> | |||
</answer> | |||
</faq> | |||
<faq id="javadoc-cannot-execute"> | |||
<question>JavaDoc failed: java.io.IOException: javadoc: cannot execute</question> | |||
<answer> | |||
<p>There is a bug in the Solaris reference implementation of | |||
the JDK, see <a href="http://developer.java.sun.com/developer/bugParade/bugs/4230399.html">http://developer.java.sun.com/developer/bugParade/bugs/4230399.html</a>. | |||
This also appears to be true under Linux, moving the JDK to | |||
the front of the PATH fixes the problem.</p> | |||
</answer> | |||
</faq> | |||
</faqsection> | |||
</document> |
@@ -0,0 +1,115 @@ | |||
<?xml version="1.0"?> | |||
<document> | |||
<properties> | |||
<author email="conor@cortexebusiness.com.au">Conor MacNeill</author> | |||
<author email="stefan.bodewig@epost.de">Stefan Bodewig</author> | |||
<title>Ant</title> | |||
</properties> | |||
<body> | |||
<section name="Ant"> | |||
<p> | |||
Ant is a Java based build tool. In theory it is kind of like make without | |||
make's wrinkles. | |||
</p> | |||
<p> | |||
Why another build tool when there is already make, gnumake, nmake, jam, and | |||
others? Because all of those tools have limitations that Ant's original author | |||
couldn't live with when developing software across multiple platforms. Make-like | |||
tools are inherently shell based. They evaluate a set of dependencies and then | |||
execute commands not unlike what you would issue on a shell. This means that you | |||
can easily extend these tools by using or writing any program for the OS that | |||
you are working on. However, this also means that you limit yourself to the OS, | |||
or at least the OS type such as Unix, that you are working on. | |||
</p> | |||
<p> | |||
Makefiles are inherently evil as well. Anybody who has worked on them for any | |||
time has run into the dreaded tab problem. "Is my command not executing | |||
because I have a space in front of my tab!!!" said the original author of | |||
Ant way too many times. Tools like Jam took care of this to a great degree, but | |||
still use yet another format to use and remember. | |||
</p> | |||
<p> | |||
Ant is different. Instead of a model where it is extended with shell based | |||
commands, it is extended using Java classes. Instead of writing shell commands, | |||
the configuration files are XML based calling out a target tree where various | |||
tasks get executed. Each task is run by an object which implements a particular | |||
Task interface. | |||
</p> | |||
<p> | |||
Granted, this removes some of the expressive power that is inherent by being | |||
able to construct a shell command such as `find . -name foo -exec rm {}` but it | |||
gives you the ability to be cross platform. To work anywhere and everywhere. And | |||
hey, if you really need to execute a shell command, Ant has an exec rule that | |||
allows different commands to be executed based on the OS that it is executing | |||
on. | |||
</p> | |||
</section> | |||
<section name="Documentation"> | |||
<p> | |||
You can view the documentation for the most recent release | |||
<a href="manual/index.html">online</a> | |||
</p> | |||
<p> | |||
Comprehensive documentation is included in the source and binary distribtions. | |||
</p> | |||
</section> | |||
<section name="Latest Release"> | |||
<p> | |||
You can download the latest release: | |||
</p> | |||
<ul> | |||
<li><a href="http://jakarta.apache.org/builds/jakarta-ant/release/v1.3/bin/"> | |||
Download the binary release</a></li> | |||
<li><a href="http://jakarta.apache.org/builds/jakarta-ant/release/v1.3/src/"> | |||
Download the source release</a></li> | |||
<li><a href="http://jakarta.apache.org/builds/jakarta-ant/release/v1.3/rpms/"> | |||
Download source and binary RPMs</a></li> | |||
</ul> | |||
</section> | |||
<section name="Nightly Builds"> | |||
<p> | |||
If you wish to use the latest Ant features, you can try downloading a nightly | |||
build from <a href="http://jakarta.apache.org/builds/jakarta-ant/nightly/">here</a> | |||
</p> | |||
</section> | |||
<section name="Towards Ant2"> | |||
<p> | |||
We are currently hashing out design details for Ant2. Please | |||
read the latest <a href="antnews.html">Ant news</a> for more details. | |||
</p> | |||
</section> | |||
<section name="Get Involved"> | |||
<ul> | |||
<li><a href="http://jakarta.apache.org/getinvolved/getinvolvedindex.html">Get Involved</a></li> | |||
<li><a href="http://jakarta.apache.org/getinvolved/mail.html">Join Mailing Lists</a></li> | |||
<li><a href="http://marc.theaimsgroup.com/?l=ant-dev&r=1&w=2">Search the Dev Mailing List</a> | |||
</li> | |||
<li><a href="http://marc.theaimsgroup.com/?l=ant-user&r=1&w=2">Search the User Mailing List</a> | |||
</li> | |||
</ul> | |||
</section> | |||
</body> | |||
</document> | |||
@@ -0,0 +1,174 @@ | |||
<?xml version="1.0" encoding="ISO-8859-1" ?> | |||
<document> | |||
<properties> | |||
<author email="stefan.bodewig@epost.de">Stefan Bodewig</author> | |||
<title>Ant Logo Proposals</title> | |||
</properties> | |||
<body> | |||
<section name="Ant needs a Logo"> | |||
<p>One of the requirements for Ant2 is, that Ant should have a | |||
logo. You can find the logos that have been proposed to the Ant | |||
mailing lists on this page.</p> | |||
<p>Tell us what you think of them (yes, <em>Powered by</em> should | |||
better be <em>Built by</em>).</p> | |||
<table> | |||
<tr> | |||
<th>Author</th><th> </th> | |||
</tr> | |||
<tr> | |||
<td>Bill J. Fellows (Bill.J.Fellows at mail.sprint.com)</td> | |||
<td><img src="images/antLogo1.png" /></td> | |||
</tr> | |||
<tr> | |||
<td>Bill J. Fellows (Bill.J.Fellows at mail.sprint.com)</td> | |||
<td><img src="images/antLogo2.png" /></td> | |||
</tr> | |||
<tr> | |||
<td>Christoph Wilhelms (Christoph.Wilhelms at t-online.de)</td> | |||
<td><img src="images/ant_logo.gif" /></td> | |||
</tr> | |||
<tr> | |||
<td>Christoph Wilhelms (Christoph.Wilhelms at t-online.de)</td> | |||
<td><img src="images/ant2_logo.gif" /></td> | |||
</tr> | |||
<tr> | |||
<td>Warner Onstine (warner at warneronstine.com)</td> | |||
<td><img src="images/ant-logo2.gif" /></td> | |||
</tr> | |||
<tr> | |||
<td>Chris Coleman (chris.coleman at csfb.com)</td> | |||
<td><img src="images/coleman.gif" /></td> | |||
</tr> | |||
<tr> | |||
<td>Stefan Lecho (Stefan.Lecho at iconmedialab.com)</td> | |||
<td><img src="images/lecho.jpg" /></td> | |||
</tr> | |||
<tr> | |||
<td>David Trogdon (DTrogdon at orgtek.com)</td> | |||
<td><img src="images/trogdon.gif" /></td> | |||
</tr> | |||
<tr> | |||
<td>Mirko Klemm (Mirko.Klemm at t-online.de)</td> | |||
<td><img src="http://www.mutantenzoo.de/antlogo-400.png" /></td> | |||
</tr> | |||
<tr> | |||
<td>Ryan P Ripley (ryan.ripley at bms.com)</td> | |||
<td><img src="images/ripley.jpg" /></td> | |||
</tr> | |||
<tr> | |||
<td>Christoph Wilhelms (Christoph.Wilhelms at t-online.de)</td> | |||
<td><img src="images/wilhelms3.gif" /></td> | |||
</tr> | |||
<tr> | |||
<td>Shane Petroff (shane at hayward.ca)</td> | |||
<td><img src="images/petroff.jpg" /></td> | |||
</tr> | |||
<tr> | |||
<td>Jim Cheesman (jchees at msl.es)</td> | |||
<td><img src="images/cheesman.jpg" /></td> | |||
</tr> | |||
<tr> | |||
<td>Kevin Duggins (Kevin.Duggins at definityhealth.com)</td> | |||
<td><img src="images/duggins.gif" /></td> | |||
</tr> | |||
<tr> | |||
<td>Kevin Duggins (Kevin.Duggins at definityhealth.com)</td> | |||
<td><img src="images/duggins2.gif" /></td> | |||
</tr> | |||
<tr> | |||
<td>Justin Ransom (Justin.Ransom at rubus.com)</td> | |||
<td><img src="images/hughes1.gif" /></td> | |||
</tr> | |||
<tr> | |||
<td>Justin Ransom (Justin.Ransom at rubus.com)</td> | |||
<td><img src="images/hughes2.gif" /></td> | |||
</tr> | |||
<tr> | |||
<td>Martin Schlömer (martin.schloemer at phase26.de)</td> | |||
<td><img src="images/schloemer.gif" /></td> | |||
</tr> | |||
<tr> | |||
<td>Martin Schlömer (martin.schloemer at phase26.de)</td> | |||
<td><img src="images/schloemer2.gif" /></td> | |||
</tr> | |||
<tr> | |||
<td>Design Services Team at Hewlett Packard (blair_hughes at hp.com></td> | |||
<td><img src="images/blairhughes_ant.jpg"/></td> | |||
</tr> | |||
<tr> | |||
<td>Design Services Team at Hewlett Packard (blair_hughes at hp.com></td> | |||
<td><img src="images/blairhughes_ant2.jpg"/></td> | |||
</tr> | |||
<tr> | |||
<td>Design Services Team at Hewlett Packard (blair_hughes at hp.com></td> | |||
<td><img src="images/blairhughes_ant3.jpg"/></td> | |||
</tr> | |||
<tr> | |||
<td>Design Services Team at Hewlett Packard (blair_hughes at hp.com></td> | |||
<td><img src="images/blairhughes_ant4.jpg"/></td> | |||
</tr> | |||
<tr> | |||
<td>Design Services Team at Hewlett Packard (blair_hughes at hp.com></td> | |||
<td><img src="images/blairhughes_ant5.jpg"/></td> | |||
</tr> | |||
<tr> | |||
<td>Design Services Team at Hewlett Packard (blair_hughes at hp.com></td> | |||
<td><img src="images/blairhughes_ant6.jpg"/></td> | |||
</tr> | |||
<tr> | |||
<td>Design Services Team at Hewlett Packard (blair_hughes at hp.com></td> | |||
<td><img src="images/blairhughes_germ1.jpg"/></td> | |||
</tr> | |||
<tr> | |||
<td>Design Services Team at Hewlett Packard (blair_hughes at hp.com></td> | |||
<td><img src="images/blairhughes_germ2.jpg"/></td> | |||
</tr> | |||
<tr> | |||
<td>Design Services Team at Hewlett Packard (blair_hughes at hp.com></td> | |||
<td><img src="images/blairhughes_germ3.jpg"/></td> | |||
</tr> | |||
<tr> | |||
<td>Design Services Team at Hewlett Packard (blair_hughes at hp.com></td> | |||
<td><img src="images/blairhughes_germ4.jpg"/></td> | |||
</tr> | |||
<tr> | |||
<td>Design Services Team at Hewlett Packard (blair_hughes at hp.com></td> | |||
<td><img src="images/blairhughes_germ5.jpg"/></td> | |||
</tr> | |||
<tr> | |||
<td>Design Services Team at Hewlett Packard (blair_hughes at hp.com></td> | |||
<td><img src="images/blairhughes_germ6.jpg"/></td> | |||
</tr> | |||
<tr> | |||
<td>Design Services Team at Hewlett Packard (blair_hughes at hp.com></td> | |||
<td><img src="images/blairhughes_keis1.jpg"/></td> | |||
</tr> | |||
<tr> | |||
<td>Design Services Team at Hewlett Packard (blair_hughes at hp.com></td> | |||
<td><img src="images/blairhughes_keis2.jpg"/></td> | |||
</tr> | |||
<tr> | |||
<td>Design Services Team at Hewlett Packard (blair_hughes at hp.com></td> | |||
<td><img src="images/blairhughes_keis3.jpg"/></td> | |||
</tr> | |||
<tr> | |||
<td>Design Services Team at Hewlett Packard (blair_hughes at hp.com></td> | |||
<td><img src="images/blairhughes_keis4.jpg"/></td> | |||
</tr> | |||
<tr> | |||
<td>Design Services Team at Hewlett Packard (blair_hughes at hp.com></td> | |||
<td><img src="images/blairhughes_keis5.jpg"/></td> | |||
</tr> | |||
<tr> | |||
<td>Alicia Kolesnikova</td> | |||
<td><img src="images/kolesnikova.gif"/></td> | |||
</tr> | |||
</table> | |||
</section> | |||
</body> | |||
</document> |
@@ -0,0 +1,164 @@ | |||
<?xml version="1.0"?> | |||
<document> | |||
<properties> | |||
<author email="conor@apache.org">Conor MacNeill</author> | |||
<title>Having Problems?</title> | |||
</properties> | |||
<body> | |||
<section name="Having Problems?"> | |||
<p>If you are having problems with Ant, this page details some steps you can take | |||
to try and resolve the problem. If you can't resolve the problem then this page will help | |||
you collect some of the relevant information to provide a bug report. This information will help | |||
the Ant developers understand and resolve the problem. Of course, not all of the steps here will | |||
make sense for every problem you encounter. These are just some suggestions to | |||
point you in the right direction. | |||
</p> | |||
<subsection name="Read the Manual"> | |||
<p>The first step to take when you have a problem is to read the <a href="manual/index.html"> | |||
manual</a> entry for the task or concept that is giving you trouble. Check particularly the meaning of | |||
attributes and nested elements. Perhaps an attribute would provide the behavior you require. If you | |||
have problems with the manual, then you can submit a documentation bug report (see below) to help us | |||
improve the Ant documentation. | |||
</p> | |||
</subsection> | |||
<subsection name="Examine Debug Output"> | |||
<p>The first step when you have a problem is to see what Ant is doing. Try running Ant with | |||
The verbose flag<br/><br/> | |||
<code>ant -verbose</code><br/><br/> | |||
or<br/><br/> | |||
<code>ant -v</code><br/><br/> | |||
This will produce something which starts like the following:</p> | |||
<source> | |||
Ant version 1.4alpha compiled on August 6 2001 | |||
Buildfile: build.xml | |||
Detected Java version: 1.3 in: f:\jdk1.3\jre | |||
Detected OS: Windows NT | |||
parsing buildfile \jakarta-ant\build.xml with | |||
URI = file:/jakarta-ant/build.xml | |||
Project base dir set to: \jakarta-ant | |||
[property] Loading \jakarta-ant\.ant.properties | |||
[property] Unable to find property file: \jakarta-ant\.ant.properties | |||
[property] Loading \conor\.ant.properties | |||
[property] Override ignored for debug | |||
prepare: | |||
check_for_optional_packages: | |||
... | |||
</source> | |||
<p> | |||
You may be able to see in this trace what ant is doing and why it takes a particular | |||
course of action. If you need even more information you can use the <code>-debug</code> | |||
flag rather than <code>-verbose</code>. This will generally produce so much output that | |||
you may want to save the output and analyze it in an editor. | |||
</p> | |||
<p>So, once you have all this debug information, how can you use it to solve your problem. | |||
That will depend on the task in question and the nature of your problem. Each task logs | |||
different aspects of its operation, but it will give you an idea of what is going on. For | |||
example, the <javac> task logs the reasons why it chooses to compile particular | |||
classes and the equivalent command it is using. The following trace (which has been edited | |||
and reformatted for clarity) shows javac adding one class but skipping another. This is followed | |||
by the compiler arguments and a summary of all the classes to be compiled. | |||
</p> | |||
<source> | |||
[javac] org\apache\tools\ant\listener\Log4jListener.java added as | |||
\build\classes\org\apache\tools\ant\listener\Log4jListener.class | |||
is outdated. | |||
[javac] org\apache\tools\ant\Location.java omitted as | |||
\build\classes\org\apache\tools\ant\Location.class is up to date. | |||
... | |||
[javac] Compiling 1 source file to \jakarta-ant\build\classes | |||
[javac] Using modern compiler | |||
[javac] Compilation args: -d \jakarta-ant\build\classes -classpath | |||
\jakarta-ant\build\classes;F:\jdk1.3\lib\tools.jar; | |||
\Ant\lib\optional.jar;\Ant\lib\log4j.jar; | |||
\Ant\lib\junit.jar;\Ant\lib\jaxp.jar; | |||
\Ant\lib\crimson.jar;\Ant\lib\ant.jar | |||
-sourcepath \jakarta-ant\src\main -g:none -O | |||
[javac] File to be compiled: | |||
\src\main\org\apache\tools\ant\listener\Log4jListener.java | |||
</source> | |||
<p> | |||
In many cases Ant tasks are wrappers around OS commands or other java classes. In debug mode, many | |||
of these tasks will print out the equivalent command line, as the <javac> task above does. If | |||
you are having a problem, it is often useful to run the command directly in the same way Ant is doing | |||
and see if the problem persists. The problem may lie in the command being run by Ant, or in the way | |||
the Ant task is running the command. You can also see the effect of changing attribute values on the | |||
generated command line. This can help you to understand whether you are using the correct attributes | |||
and values. | |||
</p> | |||
</subsection> | |||
<subsection name="Has it been fixed?"> | |||
<p> | |||
After examining the debug output, you still believe that the problem you are having may be caused by Ant. | |||
Chances are that someone else may have already encountered this problem and perhaps it has been | |||
fixed. The next step, therefore, may be to try a nightly build of Ant to see if the | |||
problem has been fixed. Nightly builds for Ant are available from the | |||
<a href="/builds/jakarta-ant/nightly/">Jakarta web site</a>. While Ant nightly | |||
builds are typically quite stable and are used by <a href="/builds/gump/latest/"> | |||
Gump</a> to build many other Jakarta projects, these builds should be treated as experimental. You can | |||
install and verify whether your problem has been fixed. Note that nightly builds do not build many of the | |||
optional tasks the come with Ant. A snapshot of these optional tasks is occasionally uploaded to the nightly | |||
download <a href="/builds/jakarta-ant/nightly/optional/">area</a>. Note that even | |||
this snapshot does not contain every optional task. | |||
</p> | |||
</subsection> | |||
<subsection name="Has it been reported?"> | |||
<p> | |||
If the current nightly build doesn't resolve your problem, it is possible that someone else has reported | |||
the issue. It is time to look at the <a href="http://nagoya.apache.org/bugzilla/">Apache Bug Database</a>. | |||
This system is easy to use and it will let you search the currently open and resolved bugs to see if your | |||
problem has already been reported. If it has, you can see whether any of the developers have commented, | |||
suggesting workarounds or the reason for the bug, etc. You may have more information to add (see about | |||
creating bug reports below), in which case, go right ahead and add it. If you can't add more information | |||
you may just want to vote for this bug, and perhaps add yourself to the CC list to follow the progress of | |||
this bug. | |||
</p> | |||
</subsection> | |||
<subsection name="Filing a Bug report"> | |||
<p>By this time you may have decided that there is a bug in Ant. You have a few choices at this | |||
point. You can send an email to the ant-user mailing list to see if others have encountered your issue | |||
and how they may have worked around it. If after some discussion, you still feel you have a bug, it | |||
is time to create a bug report. This is a simple operation in the Bug Database. Please try to provide | |||
as much information as possible to assist the developers in resolving the bug. Please try to enter correct | |||
values for the various inputs when creating the bug. Once the bug is created you can add attachments to | |||
the bug report. | |||
</p> | |||
<p>What information should you include in your bug report? The easiest bugs to fix are those which are most | |||
easily reproducible, so if you can, it is really helpful to produce a small test case that exhibits the | |||
problem. In this case, you would attach the build file and other files necessary to reproduce the problem | |||
probably packed together in an archive. If you can't produce a test case, you should try to include a | |||
snippet from your build file and the relevant sections from the debug out from Ant. Try to include the | |||
header information where Ant states the version, the OS and VM information etc. As the debug output is | |||
likely to be very large, you should try to remove the output which is not relevant. Once the bug is | |||
entered into the Bug Database, you will be kept informed about progress on the bug. If you receive email | |||
asking for further information, please try to respond as it will aid in the resolution of your bug. | |||
</p> | |||
</subsection> | |||
<subsection name="Fixing the Bug"> | |||
<p>If you aren't satisfied just filing a bug report, you can try to find and fix the problem yourself. The | |||
best way to do that is by working against the latest code from CVS. Alternatively, you can work with the | |||
source code from the source distributions available on the Jakarta website. If you are going to tackle the | |||
issues at this level, you may want to discuss details on the ant-dev mailing list. Once you have a fix | |||
for the problem, you may either submit the patch to the ant-dev mailing list or enter into the Bug | |||
Database as described above, attaching the patch. Using the Bug database has the advantage of tracking | |||
the progress of your bug. | |||
</p> | |||
</subsection> | |||
</section> | |||
</body> | |||
</document> |
@@ -0,0 +1,257 @@ | |||
<?xml version="1.0"?> | |||
<document> | |||
<properties> | |||
<author email="bodewig@apache.org">Stefan Bodewig</author> | |||
<title>Resources</title> | |||
</properties> | |||
<body> | |||
<section name="Articles and Presentations"> | |||
<p>This page lists articles and presentations written about Ant. If | |||
you've written something that should be included, please post it to one | |||
of the mailing lists.</p> | |||
</section> | |||
<section name="Articles"> | |||
<subsection name="Ant in Anger: Using Ant in a Production Development | |||
System"> | |||
<p>This document describes strategies and some basic examples of how to | |||
use Ant in larger team development projects.</p> | |||
<table> | |||
<tr> | |||
<th>Author:</th> | |||
<td><a href="mailto:steve_l@iseran.com">Steve Loughran</a></td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://cvs.apache.org/viewcvs/~checkout~/jakarta-ant/docs/ant_in_anger.html?content-type=text/html">http://cvs.apache.org/viewcvs/~checkout~/jakarta-ant/docs/ant_in_anger.html?content-type=text/html</a></td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="Ant Task Guidelines"> | |||
<p>This document describes how to write custom Ant tasks, and how to submit | |||
them to potentially be included in Ant.</p> | |||
<table> | |||
<tr> | |||
<th>Author:</th> | |||
<td><a href="mailto:steve_l@iseran.com">Steve Loughran</a></td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://cvs.apache.org/viewcvs/~checkout~/jakarta-ant/docs/ant_task_guidelines.html?content-type=text/html">http://cvs.apache.org/viewcvs/~checkout~/jakarta-ant/docs/ant_task_guidelines.html?content-type=text/html</a></td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="Incremental development with Ant and JUnit"> | |||
<p>This article explores the benefits of unit testing with Ant and | |||
JUnit, detailing how to develop automated unit tests and integrate them | |||
into your build process.</p> | |||
<table> | |||
<tr> | |||
<th>Author:</th> | |||
<td><a href="mailto:malcolm@nuearth.com">Malcolm Davis</a></td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://www-106.ibm.com/developerworks/library/j-ant/?dwzone=java">http://www-106.ibm.com/developerworks/library/j-ant/?dwzone=java</a></td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="Automate your build process using Java and Ant"> | |||
<p>This article provides an introduction to using Ant with some basic | |||
examples and by highlighting some of the important tasks.</p> | |||
<table> | |||
<tr> | |||
<th>Author:</th> | |||
<td><a href="mailto:michael.cymerman@javaworld.com">Michael Cymerman</a></td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://www.javaworld.com/javaworld/jw-10-2000/jw-1020-ant.html">http://www.javaworld.com/javaworld/jw-10-2000/jw-1020-ant.html</a></td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="Short tutorial in Cactus' (formerly J2EEUnit) | |||
documentation"> | |||
<p>There is a short tutorial on how to use Ant in Cactus' | |||
documentation. It has a slant towards build files that will be used | |||
with Cactus.</p> | |||
<table> | |||
<tr> | |||
<th>Author:</th> | |||
<td>Cactus development team</td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://jakarta.apache.org/commons/cactus/ant.html">http://jakarta.apache.org/commons/cactus/ant.html</a></td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="Developing custom Ant tasks with VisualAge for Java"> | |||
<p>This article outlines how to integrate Ant into VisualAge for Java, | |||
and how to write and debug custom tasks using the IDE and the | |||
integrated debugger.</p> | |||
<table> | |||
<tr> | |||
<th>Author:</th> | |||
<td><a href="mailto:glenn@somanetworks.com">Glenn McAllister</a></td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://www7.software.ibm.com/vad.nsf/data/document2366?OpenDocument&p=1&BCT=1&Footer=1">http://www7.software.ibm.com/vad.nsf/data/document2366?OpenDocument&p=1&BCT=1&Footer=1</a></td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="Automated builds with VisualAge for Java and Ant"> | |||
<p>This article shows how you can perform command line builds with a | |||
VisualAge for Java repository.</p> | |||
<table> | |||
<tr> | |||
<th>Author:</th> | |||
<td><a href="mailto:glenn@somanetworks.com">Glenn McAllister</a></td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://www7.software.ibm.com/vad.nsf/Data/Document4366?OpenDocument&p=1&BCT=3&Footer=1">http://www7.software.ibm.com/vad.nsf/Data/Document4366?OpenDocument&p=1&BCT=3&Footer=1</a></td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="Ant: A Build Tool from the Jakarta Project"> | |||
<p>This article is from the "Best Practices" section of | |||
Sun's Dot-Com Builder Site.</p> | |||
<table> | |||
<tr> | |||
<th>Author:</th> | |||
<td>Laura Geele Wang</td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://dcb.sun.com/practices/profiles/ant.jsp">http://dcb.sun.com/practices/profiles/ant.jsp</a></td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="Making a Mountain Out of an Anthill"> | |||
<p>This article is from the June 2001 issue of the Java Developer' | |||
Journal. You need to be a registered JDJ subscriber to view this | |||
article.</p> | |||
<table> | |||
<tr> | |||
<th>Author:</th> | |||
<td>Neal Ford</td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://www.sys-con.com/java/archivesa.cfm?volume=06&issue=06">http://www.sys-con.com/java/archivesa.cfm?volume=06&issue=06</a></td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="Using Ant and Weblogic EJBs"> | |||
<p>This article describes how to use Ant to create Weblogic EJBs, and | |||
some workarounds for issues you may encounter.</p> | |||
<table> | |||
<tr> | |||
<th>Author:</th> | |||
<td>Jesse E. Tilly</td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://www.onjava.com/pub/a/onjava/2001/06/25/antejb.html">http://www.onjava.com/pub/a/onjava/2001/06/25/antejb.html</a></td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="An Introduction to Ant"> | |||
<p>This article is a short introduction into the basic | |||
concepts of Ant.</p> | |||
<table> | |||
<tr> | |||
<th>Author:</th> | |||
<td>Jayakrishnan Nair</td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://varnam.org/articles/ant.html">http://varnam.org/articles/ant.html</a></td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
</section> | |||
<section name="Presentations"> | |||
<subsection name="Ant Build Tool"> | |||
<p>A PowerPoint presentation on Ant 1.2. It provides a basic overview | |||
of Ant's capabilities.</p> | |||
<table> | |||
<tr> | |||
<th>Author:</th> | |||
<td><a href="mailto:chanezon@netscape.com">Patrick Chanezon</a></td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://people.netscape.com/chanezon/tech/ant/ant_preso.ppt">http://people.netscape.com/chanezon/tech/ant/ant_preso.ppt</a></td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="Ant"> | |||
<p>A detailed Ant 1.3 PowerPoint presentation, made at the St. Louis Java Users Group | |||
meeting in March 2001. Includes a detailed build file and basic | |||
descriptions of all the built in and optional tasks.</p> | |||
<table> | |||
<tr> | |||
<th>Author:</th> | |||
<td>Mark Volkmann</td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://www.ociweb.com/javasig/knowledgebase/March2001/index.html">http://www.ociweb.com/javasig/knowledgebase/March2001/index.html</a></td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
<subsection name="Modern Development Crises"> | |||
<p>This presentation is an overview of the current state of software | |||
development today. There are a couple of slides that briefly cover | |||
Ant.</p> | |||
<table> | |||
<tr> | |||
<th>Author:</th> | |||
<td><a href="mailto:steve_l@iseran.com">Steve Loughran</a></td> | |||
</tr> | |||
<tr> | |||
<th>URL:</th> | |||
<td><a href="http://www.iseran.com/Steve/modern_development_processes.html">http://www.iseran.com/Steve/modern_development_processes.html</a></td> | |||
</tr> | |||
</table> | |||
</subsection> | |||
</section> | |||
</body> | |||
</document> |
@@ -0,0 +1,118 @@ | |||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> | |||
<!-- Content Stylesheet for Site --> | |||
## Defined variables | |||
#set ($bodybg = "#ffffff") | |||
#set ($bodyfg = "#000000") | |||
#set ($bodylink = "#525D76") | |||
#set ($bannerbg = "#525D76") | |||
#set ($bannerfg = "#ffffff") | |||
#set ($subbannerbg = "#828DA6") | |||
#set ($subbannerfg = "#ffffff") | |||
#set ($tablethbg = "#039acc") | |||
#set ($tabletdbg = "#a0ddf0") | |||
#set ($pound = "#" ) | |||
<!-- start the processing --> | |||
#faqs() | |||
<!-- end the processing --> | |||
## This is where the FAQ specific macro's live | |||
#macro (toc $section) | |||
<table border="0" cellspacing="0" cellpadding="2" width="100%"> | |||
<tr><td bgcolor="$subbannerbg"> | |||
<font color="$subbannerfg" face="arial,helvetica,sanserif"> | |||
<strong>$section.getAttributeValue("title")</strong> | |||
</font> | |||
</td></tr> | |||
<tr><td> | |||
<blockquote> | |||
<ul> | |||
#foreach ($faq in $section.getChildren("faq") ) | |||
#subtoc ($faq) | |||
#end | |||
</ul> | |||
</blockquote> | |||
</td></tr> | |||
</table> | |||
#end | |||
#macro (subtoc $faq) | |||
#set ($id = $faq.getAttributeValue("id")) | |||
<li><a href="$pound$id"> | |||
$xmlout.outputString($faq.getChild("question"), true) | |||
</a></li> | |||
#end | |||
#macro (answers $section) | |||
#foreach ($faq in $section.getChildren("faq") ) | |||
#faq ($faq) | |||
#end | |||
#end | |||
#macro (faq $faq) | |||
#set ($id = $faq.getAttributeValue("id")) | |||
<a name="$id"> | |||
<table border="0" cellspacing="0" cellpadding="2" width="100%"> | |||
<tr><td bgcolor="$subbannerbg"> | |||
<font color="$subbannerfg" face="arial,helvetica,sanserif"> | |||
<strong> | |||
$xmlout.outputString($faq.getChild("question"), true) | |||
</strong> | |||
</font> | |||
</td></tr> | |||
<tr><td> | |||
<blockquote> | |||
#foreach ($item in $faq.getChild("answer").getChildren()) | |||
#if ($item.getName().equals("img")) | |||
#image ($item) | |||
#elseif ($item.getName().equals("source")) | |||
#source ($item) | |||
#elseif ($item.getName().equals("table")) | |||
#table ($item) | |||
#else | |||
$xmlout.outputString($item) | |||
#end | |||
#end | |||
</blockquote> | |||
</td></tr> | |||
</table> | |||
</a> | |||
#end | |||
#macro (faqs) | |||
#header() | |||
<table border="0" cellspacing="0" cellpadding="2" width="100%"> | |||
<tr><td bgcolor="$bannerbg"> | |||
<font color="$bannerfg" face="arial,helvetica,sanserif"> | |||
<strong>Questions</strong> | |||
</font> | |||
</td></tr> | |||
<tr><td> | |||
<blockquote> | |||
#set ($allFaqSections = $root.getChildren("faqsection")) | |||
#foreach ( $faqSection in $allFaqSections ) | |||
#toc ($faqSection) | |||
#end | |||
</blockquote> | |||
</td></tr> | |||
</table> | |||
<table border="0" cellspacing="0" cellpadding="2" width="100%"> | |||
<tr><td bgcolor="$bannerbg"> | |||
<font color="$bannerfg" face="arial,helvetica,sanserif"> | |||
<strong>Answers</strong> | |||
</font> | |||
</td></tr> | |||
<tr><td> | |||
<blockquote> | |||
#foreach ( $faqSection in $allFaqSections ) | |||
#answers ($faqSection) | |||
#end | |||
</blockquote> | |||
</td></tr> | |||
</table> | |||
#footer() | |||
#end |
@@ -0,0 +1,50 @@ | |||
<?xml version="1.0" encoding="ISO-8859-1"?> | |||
<project name="Jakarta Site" | |||
href="http://jakarta.apache.org/"> | |||
<title>The Jakarta Site</title> | |||
<!-- uncomment and put your project logo here! | |||
<logo href="http://jakarta.apache.org/images/jakarta-logo.gif">The Jakarta Project</logo> | |||
--> | |||
<body> | |||
<menu name="Ant"> | |||
<item name="Front Page" | |||
href="/index.html"/> | |||
<item name="News" | |||
href="/antnews.html"/> | |||
<item name="Documentation" | |||
href="/manual/"/> | |||
<item name="External Tools and Tasks" | |||
href="/external.html"/> | |||
<item name="Resources" | |||
href="/resources.html"/> | |||
<item name="Ant FAQ" | |||
href="/faq.html"/> | |||
<item name="Having Problems?" | |||
href="/problems.html"/> | |||
</menu> | |||
<menu name="Download"> | |||
<item name="Binaries" href="/site/binindex.html"/> | |||
<item name="Source Code" href="/site/sourceindex.html"/> | |||
</menu> | |||
<menu name="Jakarta"> | |||
<item name="News & Status" href="/site/news.html"/> | |||
<item name="Mission" href="/site/mission.html"/> | |||
<item name="Guidelines Notes" href="/site/guidelines.html"/> | |||
<item name="FAQs" href="/site/faqs.html"/> | |||
</menu> | |||
<menu name="Get Involved"> | |||
<item name="Overview" href="/site/getinvolved.html"/> | |||
<item name="CVS Repositories" href="/site/cvsindex.html"/> | |||
<item name="Mailing Lists" href="/site/mail.html"/> | |||
<item name="Reference Library" href="/site/library.html"/> | |||
<item name="Bug Database" href="http://nagoya.apache.org/bugzilla/enter_bug.cgi?product=Ant"/> | |||
<item name="Enhancement Requests" href="http://nagoya.apache.org/bugzilla/enter_bug.cgi?product=Ant&bug_severity=Enhancement"/> | |||
</menu> | |||
</body> | |||
</project> |
@@ -0,0 +1,81 @@ | |||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> | |||
<!-- Content Stylesheet for Site --> | |||
## Defined variables | |||
#set ($bodybg = "#ffffff") | |||
#set ($bodyfg = "#000000") | |||
#set ($bodylink = "#525D76") | |||
#set ($bannerbg = "#525D76") | |||
#set ($bannerfg = "#ffffff") | |||
#set ($subbannerbg = "#828DA6") | |||
#set ($subbannerfg = "#ffffff") | |||
#set ($tablethbg = "#039acc") | |||
#set ($tabletdbg = "#a0ddf0") | |||
<!-- start the processing --> | |||
#document() | |||
<!-- end the processing --> | |||
## This is where the common page macro's live | |||
#macro ( subsection $subsection) | |||
<table border="0" cellspacing="0" cellpadding="2" width="100%"> | |||
<tr><td bgcolor="$subbannerbg"> | |||
<font color="$subbannerfg" face="arial,helvetica,sanserif"> | |||
<a name="$subsection.getAttributeValue("name")"><strong>$subsection.getAttributeValue("name")</strong></a> | |||
</font> | |||
</td></tr> | |||
<tr><td> | |||
<blockquote> | |||
#foreach ( $items in $subsection.getChildren() ) | |||
#if ($items.getName().equals("img")) | |||
#image ($items) | |||
#elseif ($items.getName().equals("source")) | |||
#source ($items) | |||
#elseif ($items.getName().equals("table")) | |||
#table ($items) | |||
#else | |||
$xmlout.outputString($items) | |||
#end | |||
#end | |||
</blockquote> | |||
</td></tr> | |||
</table> | |||
#end | |||
#macro ( section $section) | |||
<table border="0" cellspacing="0" cellpadding="2" width="100%"> | |||
<tr><td bgcolor="$bannerbg"> | |||
<font color="$bannerfg" face="arial,helvetica,sanserif"> | |||
<a name="$section.getAttributeValue("name")"><strong>$section.getAttributeValue("name")</strong></a> | |||
</font> | |||
</td></tr> | |||
<tr><td> | |||
<blockquote> | |||
#foreach ( $items in $section.getChildren() ) | |||
#if ($items.getName().equals("img")) | |||
#image ($items) | |||
#elseif ($items.getName().equals("source")) | |||
#source ($items) | |||
#elseif ($items.getName().equals("table")) | |||
#table ($items) | |||
#elseif ($items.getName().equals("subsection")) | |||
#subsection ($items) | |||
#else | |||
$xmlout.outputString($items) | |||
#end | |||
#end | |||
</blockquote> | |||
</td></tr> | |||
</table> | |||
#end | |||
#macro (document) | |||
#header() | |||
#set ($allSections = $root.getChild("body").getChildren("section")) | |||
#foreach ( $section in $allSections ) | |||
#section ($section) | |||
#end | |||
#footer() | |||
#end |
@@ -0,0 +1,196 @@ | |||
## This is where the common macro's live | |||
#macro ( table $table) | |||
<table> | |||
#foreach ( $items in $table.getChildren() ) | |||
#if ($items.getName().equals("tr")) | |||
#tr ($items) | |||
#end | |||
#end | |||
</table> | |||
#end | |||
#macro ( tr $tr) | |||
<tr> | |||
#foreach ( $items in $tr.getChildren() ) | |||
#if ($items.getName().equals("td")) | |||
#td ($items) | |||
#elseif ($items.getName().equals("th")) | |||
#th ($items) | |||
#end | |||
#end | |||
</tr> | |||
#end | |||
#macro ( td $value) | |||
#if ($value.getAttributeValue("colspan")) | |||
#set ($colspan = $value.getAttributeValue("colspan")) | |||
#end | |||
#if ($value.getAttributeValue("rowspan")) | |||
#set ($rowspan = $value.getAttributeValue("rowspan")) | |||
#end | |||
<td bgcolor="$tabletdbg" colspan="$!colspan" rowspan="$!rowspan" | |||
valign="top" align="left"> | |||
<font color="#000000" size="-1" face="arial,helvetica,sanserif"> | |||
#if ($value.getText().length() != 0 || $value.hasChildren()) | |||
$xmlout.outputString($value, true) | |||
#else | |||
| |||
#end | |||
</font> | |||
</td> | |||
#end | |||
#macro ( th $value) | |||
#if ($value.getAttributeValue("colspan")) | |||
#set ($colspan = $value.getAttributeValue("colspan")) | |||
#end | |||
#if ($value.getAttributeValue("rowspan")) | |||
#set ($rowspan = $value.getAttributeValue("rowspan")) | |||
#end | |||
<td bgcolor="$tablethbg" colspan="$!colspan" rowspan="$!rowspan" | |||
valign="top" align="left"> | |||
<font color="#000000" size="-1" face="arial,helvetica,sanserif"> | |||
#if ($value.getText().length() != 0 || $value.hasChildren()) | |||
$xmlout.outputString($value, true) | |||
#else | |||
| |||
#end | |||
</font> | |||
</td> | |||
#end | |||
#macro ( projectanchor $name $value ) | |||
#if ($value.startsWith("http://")) | |||
<a href="$value">$name</a> | |||
#elseif ($value.startsWith("/site")) | |||
<a href="http://jakarta.apache.org$value">$name</a> | |||
#else | |||
<a href="$relativePath$value">$name</a> | |||
#end | |||
#end | |||
#macro ( metaauthor $author $email ) | |||
<meta name="author" value="$author"> | |||
<meta name="email" value="$email"> | |||
#end | |||
#macro ( image $value ) | |||
#if ($value.getAttributeValue("width")) | |||
#set ($width=$value.getAttributeValue("width")) | |||
#end | |||
#if ($value.getAttributeValue("height")) | |||
#set ($height=$value.getAttributeValue("height")) | |||
#end | |||
#if ($value.getAttributeValue("align")) | |||
#set ($align=$value.getAttributeValue("align")) | |||
#end | |||
<img src="$relativePath$value.getAttributeValue("src")" | |||
width="$!width" height="$!height" align="$!align"> | |||
#end | |||
#macro ( source $value) | |||
<div align="left"> | |||
<table cellspacing="4" cellpadding="0" border="0"> | |||
<tr> | |||
<td bgcolor="#023264" width="1" height="1"><img src="/images/void.gif" width="1" height="1" vspace="0" hspace="0" border="0"/></td> | |||
<td bgcolor="#023264" height="1"><img src="/images/void.gif" width="1" height="1" vspace="0" hspace="0" border="0"/></td> | |||
<td bgcolor="#023264" width="1" height="1"><img src="/images/void.gif" width="1" height="1" vspace="0" hspace="0" border="0"/></td> | |||
</tr> | |||
<tr> | |||
<td bgcolor="#023264" width="1"><img src="/images/void.gif" width="1" height="1" vspace="0" hspace="0" border="0"/></td> | |||
<td bgcolor="#ffffff"><pre>$escape.getText($value.getText())</pre></td> | |||
<td bgcolor="#023264" width="1"><img src="/images/void.gif" width="1" height="1" vspace="0" hspace="0" border="0"/></td> | |||
</tr> | |||
<tr> | |||
<td bgcolor="#023264" width="1" height="1"><img src="/images/void.gif" width="1" height="1" vspace="0" hspace="0" border="0"/></td> | |||
<td bgcolor="#023264" height="1"><img src="/images/void.gif" width="1" height="1" vspace="0" hspace="0" border="0"/></td> | |||
<td bgcolor="#023264" width="1" height="1"><img src="/images/void.gif" width="1" height="1" vspace="0" hspace="0" border="0"/></td> | |||
</tr> | |||
</table> | |||
</div> | |||
#end | |||
#macro ( makeProject ) | |||
#set ($menus = $project.getChild("body").getChildren("menu")) | |||
#foreach ( $menu in $menus ) | |||
<p><strong>$menu.getAttributeValue("name")</strong></p> | |||
<ul> | |||
#foreach ( $item in $menu.getChildren() ) | |||
#set ($name = $item.getAttributeValue("name")) | |||
<li>#projectanchor($name $item.getAttributeValue("href"))</li> | |||
#end | |||
</ul> | |||
#end | |||
#end | |||
#macro (getProjectImage) | |||
#if ($project.getChild("logo")) | |||
<td align="left"> | |||
<a href="http://jakarta.apache.org"><img src="http://jakarta.apache.org/images/jakarta-logo.gif" border="0"/></a> | |||
</td> | |||
<td align="right"> | |||
#set ( $logoString = $project.getChild("logo").getAttributeValue("href") ) | |||
#if ( $logoString.startsWith("/") ) | |||
<a href="$project.getAttributeValue("href")"><img src="$relativePath$logoString" alt="$project.getChild("logo").getText()" border="0"/></a> | |||
#else | |||
<a href="$project.getAttributeValue("href")"><img src="$relativePath/$logoString" alt="$project.getChild("logo").getText()" border="0"/></a> | |||
#end | |||
</td> | |||
#else | |||
<td colspan="2"> | |||
<a href="http://jakarta.apache.org"><img src="http://jakarta.apache.org/images/jakarta-logo.gif" align="left" border="0"/></a> | |||
</td> | |||
#end | |||
#end | |||
#macro (header) | |||
<html> | |||
<head> | |||
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"/> | |||
#set ($authors = $root.getChild("properties").getChildren("author")) | |||
#foreach ( $au in $authors ) | |||
#metaauthor ( $au.getText() $au.getAttributeValue("email") ) | |||
#end | |||
<title>$project.getChild("title").getText() - $root.getChild("properties").getChild("title").getText()</title> | |||
</head> | |||
<body bgcolor="$bodybg" text="$bodyfg" link="$bodylink"> | |||
<table border="0" width="100%" cellspacing="0"> | |||
<!-- TOP IMAGE --> | |||
<tr> | |||
#getProjectImage() | |||
</tr> | |||
</table> | |||
<table border="0" width="100%" cellspacing="4"> | |||
<tr><td colspan="2"> | |||
<hr noshade="" size="1"/> | |||
</td></tr> | |||
<tr> | |||
<!-- LEFT SIDE NAVIGATION --> | |||
<td valign="top" nowrap="true"> | |||
#makeProject() | |||
</td> | |||
<td align="left" valign="top"> | |||
#end | |||
#macro (footer) | |||
</td> | |||
</tr> | |||
<!-- FOOTER --> | |||
<tr><td colspan="2"> | |||
<hr noshade="" size="1"/> | |||
</td></tr> | |||
<tr><td colspan="2"> | |||
<div align="center"><font color="$bodylink" size="-1"><em> | |||
Copyright © 1999-2001, Apache Software Foundation | |||
</em></font></div> | |||
</td></tr> | |||
</table> | |||
</body> | |||
</html> | |||
#end |
@@ -0,0 +1,2 @@ | |||
file.resource.loader.path=xdocs/stylesheets | |||
velocimacro.library=templates.vm |