umagesh 02/02/04 13:50:42
Modified: docs/manual/CoreTasks tar.html
Log:
Document new attributes.
PR: 5874
Submitted by: Stefan Heimann ([EMAIL PROTECTED])
Revision Changes Path
1.15 +38 -0 jakarta-ant/docs/manual/CoreTasks/tar.html
Index: tar.html
===================================================================
RCS file: /home/cvs/jakarta-ant/docs/manual/CoreTasks/tar.html,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- tar.html 3 Feb 2002 22:23:37 -0000 1.14
+++ tar.html 4 Feb 2002 21:50:42 -0000 1.15
@@ -136,6 +136,20 @@
are prefixed with that path in the archive.</td>
<td align="center" valign="top">No</td>
</tr>
+ <tr>
+ <td valign="top">fullpath</td>
+ <td valign="top">If the fullpath attribute is set, the file in the
fileset
+ is written with that path in the archive. The prefix attribute, if
specified, is
+ ignored. It is an error to have more than one file specified in
+ such a fileset.</td>
+ <td align="center" valign="top">No</td>
+ </tr>
+ <tr>
+ <td valign="top">preserveLeadingSlashes</td>
+ <td valign="top">Indicates whether leading `/'s should
+ be preserved in the file names. Default is <code>false</code>.</td>
+ <td align="center" valign="top">No</td>
+ </tr>
</table>
<h3>Examples</h3>
@@ -151,6 +165,30 @@
<p>tars all files in the <code>htdocs/manual</code> directory into a file
called <code>manual.tar</code>
in the <code>${dist}</code> directory. Files in the directory
<code>mydocs</code>,
or files with the name <code>todo.html</code> are excluded.</p>
+
+<pre>
+<tar destfile="${basedir}/docs.tar">
+ <tarfileset dir="${dir.src}/docs"
+ fullpath="/usr/doc/ant/README"
+ preserveLeadingSlashes="true">
+ <include name="readme.txt"/>
+ </tarfileset>
+ <tarfileset dir="${dir.src}/docs"
+ prefix="/usr/doc/ant"
+ preserveLeadingSlashes="true">
+ <include name="*.html"/>
+ </tarfileset>
+</tar></pre>
+
+<p>
+ Writes the file <code>docs/readme.txt</code> as
+ <code>/usr/doc/ant/README</code> into the archive. All
+ <code>*.html</code> files in the <code>docs</code> directory are
+ prefixed by <code>/usr/doc/ant</code>, so for example
+ <code>docs/index.html</code> is written as
+ <code>/usr/doc/ant/index.html</code> to the archive.
+</p>
+
<pre><tar longfile="gnu"
destfile="${dist.base}/${dist.name}-src.tar" >
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>