You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ant.apache.org by bo...@apache.org on 2001/12/12 12:05:34 UTC
cvs commit: jakarta-ant/docs/manual/CoreTasks jar.html manifest.html
bodewig 01/12/12 03:05:34
Modified: docs/manual/CoreTasks jar.html manifest.html
Log:
improve documentation of manifest task, using Conor's patch that
caught me mid-flight as a basis.
We really should coordinate from time to time 8-)
Revision Changes Path
1.12 +5 -56 jakarta-ant/docs/manual/CoreTasks/jar.html
Index: jar.html
===================================================================
RCS file: /home/cvs/jakarta-ant/docs/manual/CoreTasks/jar.html,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -r1.11 -r1.12
--- jar.html 2001/12/12 10:31:25 1.11
+++ jar.html 2001/12/12 11:05:34 1.12
@@ -137,71 +137,20 @@
ignored and you will get a warning.</p>
<h4>Manifest</h4>
+<p>The manifest nested element allows the manifest for the Jar file to
+be provided inline in the build file rather than in an external
+file. This element is identical to the
+<a href="manifest.html">manifest</a> task, but its file and mode
+attributes will be ignored.</p>
<p>
-The manifest nested element allows the manifest for the Jar file to be
-provided inline in the build file rather than in an external file. This
-makes it easy to produce Jar manifests which take values from Ant properties.
If both an inline manifest and an external file are both specified, the
manifests are merged.
</p>
-<p>
-The manifest element supports nested elements to reflect the structure of
-manifests, according to the
-<a href="http://java.sun.com/j2se/1.3/docs/guide/jar/jar.html">Jar file
-specification</a>. Specifically, a manifest
-element consists of a set of attributes and sections. These sections in turn
-may contain attributes.
-</p>
<p>When using inline manifests, the Jar task will check whether the build
file is more recent that the Jar file when deciding whether to rebuild the
Jar. This will not take into account property file changes which may affect
the resulting Jar.
-</p>
-
-<p> The manifest element itself does not support any attributes. It serves
-merely as a container for the attribute and section elements that make up the
-manifest. The attributes of those elements are as follows:
-</p>
-<p>
-<b>Section</b>
-</p>
-<p>
-<table border="1" cellpadding="2" cellspacing="0">
- <tr>
- <td valign="top"><b>Attribute</b></td>
- <td valign="top"><b>Description</b></td>
- <td align="center" valign="top"><b>Required</b></td>
- </tr>
- <tr>
- <td valign="top">Name</td>
- <td valign="top">The name of the section</td>
- <td valign="top" align="center">Yes</td>
- </tr>
-</table>
-</p>
-
-<p>
-<b>Attribute</b>
-</p>
-<p>
-<table border="1" cellpadding="2" cellspacing="0">
- <tr>
- <td valign="top"><b>Attribute</b></td>
- <td valign="top"><b>Description</b></td>
- <td align="center" valign="top"><b>Required</b></td>
- </tr>
- <tr>
- <td valign="top">Name</td>
- <td valign="top">The name of the attribute</td>
- <td valign="top" align="center">Yes</td>
- </tr>
- <tr>
- <td valign="top">Value</td>
- <td valign="top">The value of the attribute</td>
- <td valign="top" align="center">Yes</td>
- </tr>
-</table>
</p>
<h3>Examples</h3>
1.2 +31 -1 jakarta-ant/docs/manual/CoreTasks/manifest.html
Index: manifest.html
===================================================================
RCS file: /home/cvs/jakarta-ant/docs/manual/CoreTasks/manifest.html,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- manifest.html 2001/12/12 10:54:08 1.1
+++ manifest.html 2001/12/12 11:05:34 1.2
@@ -14,6 +14,14 @@
<p>This task can be used to write a Manifest file, optionally
replacing or updating an existing file.</p>
+<p>Manifests are processed according to the
+<a href="http://java.sun.com/j2se/1.3/docs/guide/jar/jar.html">Jar
+file specification.</a>. Specifically, a manifest element consists of
+a set of attributes and sections. These sections in turn may contain
+attributes. Note in particular that this may result in manifest lines
+greater than 72 bytes being wrapped and continued on the next
+line.</p>
+
<h3>Parameters</h3>
<table border="1" cellpadding="2" cellspacing="0">
<tr>
@@ -28,7 +36,7 @@
</tr>
<tr>
<td valign="top">mode</td>
- <td valign="top">One of "update" or "replace", default is "update".</td>
+ <td valign="top">One of "update" or "replace", default is "replace".</td>
<td valign="top" align="center">No</td>
</tr>
</table>
@@ -73,6 +81,28 @@
to be the main section.</td>
</tr>
</table>
+
+<h3>Examples</h3>
+
+<pre>
+ <manifest file="MANIFEST.MF">
+ <attribute name="Built-By" value="${user.name}"/>
+ <section name="common/class1.class">
+ <attribute name="Sealed" value="false"/>
+ </section>
+ </manifest>
+</pre>
+
+<p>Creates or replaces the file MANIFEST.MF. Note that the Built-By
+attribute will take the value of the Ant property ${user.name}. The
+manifest produced by the above would look like this:
+</p>
+<pre><code>Manifest-Version: 1.0
+Built-By: bodewig
+Created-By: Apache Ant 1.5alpha
+
+Name: common/class1.class
+Sealed: false</code></pre>
</body>
</html>
--
To unsubscribe, e-mail: <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>