duplicate (attribute): behavior when a duplicate file is found. Valid values are add, preserve, and fail. The default value is add.
zipgroupfileset (nested fileset): allows for multiple zip files to be merged into the archive. Each file found in this fileset is added to the archive the same way that "zipfileset src" files are added.
Jar task
duplicate/zipgroupfileset: same as in Zip task
filesetmanifest (attribute): behavior when a Manifest is found in a zipfileset or zipgroupfileset file is found. Valid values are skip, merge, and mergewithoutmain. mergewill merge all of manifests together, and merge this into any other specified manifests mergewithoutmain merges everything but the Main section of the manifests. Default value is skip
manifest (existing attribute): this attribute now also accepts the name of a jar added through a fileset. If its the name of an added jar, the task expects the manifest to be in the jar at META-INF/Manifest.mf
Submitted by: Brian Deitte <bdeitte@macromedia.com>
PR: 5667, 5036
git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@271698 13f79535-47bb-0310-9956-ffa450edef68
@@ -28,11 +28,12 @@ supports all attributes of <code><fileset></code>
<code><patternset></code> elements.</p>
<code><patternset></code> elements.</p>
<p>You can also use nested file sets for more flexibility, and specify
<p>You can also use nested file sets for more flexibility, and specify
multiple ones to merge together different trees of files into one JAR.
multiple ones to merge together different trees of files into one JAR.
The extended fileset attributes from the zip task are also available
in the jar task.
The extended fileset and groupfileset attributes from the zip task are
also available in the jar task.
See the <a href="zip.html">Zip</a> task for more details and examples.</p>
See the <a href="zip.html">Zip</a> task for more details and examples.</p>
<p>If the manifest is omitted, a simple one will be supplied by Ant.
<p>If the manifest is omitted, a simple one will be supplied by Ant.
You should not include <samp>META-INF/MANIFEST.MF</samp> in your set of files.</p>
If there is a manifest or manifests in your set of files, these manifests can
be used if <i>filesetmanifests</i> is set to <i>merge</i> or <i>mergewithoutmain</i>.</p>
<p>The <code>update</code> parameter controls what happens if the
<p>The <code>update</code> parameter controls what happens if the
JAR file already exists. When set to <code>yes</code>, the JAR file is
JAR file already exists. When set to <code>yes</code>, the JAR file is
updated with the files specified. When set to <code>no</code> (the
updated with the files specified. When set to <code>no</code> (the
@@ -117,7 +118,13 @@ being wrapped and continued on the next line.
</tr>
</tr>
<tr>
<tr>
<td valign="top">manifest</td>
<td valign="top">manifest</td>
<td valign="top">the manifest file to use.</td>
<td valign="top">the manifest file to use. This can be either the location of a manifest, or the name of a jar added through a fileset. If its the name of an added jar, the task expects the manifest to be in the jar at META-INF/MANIFEST.MF</td>
<td valign="top" align="center">No</td>
</tr>
<tr>
<td valign="top">filesetmanifest</td>
<td valign="top">behavior when a Manifest is found in a zipfileset or zipgroupfileset file is found. Valid values are "skip", "merge", and "mergewithoutmain". "merge" will merge all of manifests together, and merge this into any other specified manifests. "mergewithoutmain" merges everything but the Main section of the manifests. Default value is "skip".
</td>
<td valign="top" align="center">No</td>
<td valign="top" align="center">No</td>
</tr>
</tr>
<tr>
<tr>
@@ -126,6 +133,21 @@ being wrapped and continued on the next line.
the destination file if it already exists.</td>
the destination file if it already exists.</td>
<td valign="top" align="center">No</td>
<td valign="top" align="center">No</td>
</tr>
</tr>
<tr>
<td valign="top">whenempty</td>
<td valign="top">behavior when no files match. Valid values are "fail", "skip", and "create". Default is "skip".</td>
<td valign="top" align="center">No</td>
</tr>
<tr>
<td valign="top">duplicate</td>
<td valign="top">behavior when a duplicate file is found. Valid values are "add", "preserve", and "fail". The default value is "add". </td>
<td valign="top" align="center">No</td>
</tr>
<tr>
<td valign="top">index</td>
<td valign="top">whether to create an <A HREF="http://java.sun.com/j2se/1.3/docs/guide/jar/jar.html#JAR%20Index">index list</A> to speed up classloading. This is a JDK 1.3+ specific feature. Defaults to false. </td>
@@ -33,6 +33,9 @@ if <code>basedir</code> is set. You may use any mixture of the implicit file set
and optional subelements like <code><include></code>); explicit nested
and optional subelements like <code><include></code>); explicit nested
<code><fileset></code> elements so long as at least one fileset total is specified. The ZIP file will
<code><fileset></code> elements so long as at least one fileset total is specified. The ZIP file will
only reflect the relative paths of files <i>within</i> each fileset. The Zip task and its derivatives know a special form of a fileset named zipfileset that has additional attributes (described below). </p>
only reflect the relative paths of files <i>within</i> each fileset. The Zip task and its derivatives know a special form of a fileset named zipfileset that has additional attributes (described below). </p>
<p>The Zip task also supports the merging of multiple zip files into the zip file.
This is possible through either the <i>src</i> attribute of any nested filesets
or by using the special nested fileset <i>zipgroupfileset</i>.</p>
<p>The <code>update</code> parameter controls what happens if the
<p>The <code>update</code> parameter controls what happens if the
ZIP file already exists. When set to <code>yes</code>, the ZIP file is
ZIP file already exists. When set to <code>yes</code>, the ZIP file is
updated with the files specified. (New files are added; old files are
updated with the files specified. (New files are added; old files are
@@ -122,7 +125,12 @@ Java.</p>
</tr>
</tr>
<tr>
<tr>
<td valign="top">whenempty</td>
<td valign="top">whenempty</td>
<td valign="top">Behavior when no files match.</td>
<td valign="top">behavior when no files match. Valid values are "fail", "skip", and "create". Default is "skip".</td>
<td valign="top" align="center">No</td>
</tr>
<tr>
<td valign="top">duplicate</td>
<td valign="top">behavior when a duplicate file is found. Valid values are "add", "preserve", and "fail". The default value is "add". </td>
<td valign="top" align="center">No</td>
<td valign="top" align="center">No</td>
</tr>
</tr>
</table>
</table>
@@ -140,6 +148,11 @@ exact location in the archive. (The <i>fullpath</i> attribute can only be set fo
may be used in place of the <i>dir</i> attribute to specify a zip file whose
may be used in place of the <i>dir</i> attribute to specify a zip file whose
contents will be extracted and included in the archive. As with directories, include and exclude patterns may be used to specify a subset of the zip file
contents will be extracted and included in the archive. As with directories, include and exclude patterns may be used to specify a subset of the zip file
for inclusion in the archive.</p>
for inclusion in the archive.</p>
<h4>zipgroupfileset</h4>
<p>A <code><zipgroupfileset></code> allows for multiple zip files to be
merged into the archive. Each file found in this fileset is added to the archive
the same way that <i>zipfileset src</i> files are added.</p>
<p>zips all files in the <code>htdocs/manual</code> directory into the <code>docs/user-guide</code> directory in the archive and includes all the files in any file that maches <code>examples*.zip</code>, such as all files within <code>examples1.zip</code> or <code>examples_for_brian.zip</code>.
<p><i>This task has been deprecated. Use the zipfileset and zipgroupfileset attributes of the <a href="../CoreTasks/jar.html">Jar task</a> or <a href="../CoreTasks/zip.html">Zip task</a> instead.</i></p>
<h3><b>Description:</b></h3>
<h3><b>Description:</b></h3>
<p>Links entries from sub-builds and libraries.</p>
<p>Links entries from sub-builds and libraries.</p>
Thank you for your continuous support to the Openl Qizhi Community AI Collaboration Platform. In order to protect your usage rights and ensure network security, we updated the Openl Qizhi Community AI Collaboration Platform Usage Agreement in January 2024. The updated agreement specifies that users are prohibited from using intranet penetration tools. After you click "Agree and continue", you can continue to use our services. Thank you for your cooperation and understanding.