ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tom Dimock <t...@cornell.edu>
Subject Re: delete question
Date Wed, 14 Jun 2000 20:06:48 GMT
At 09:59 PM 06/14/2000 +0200, Jakob wrote:
>Ofcourse it should be added to the core, it's a major limitation.
>
>Can't committers just contribute it?
>
>Do remember to add it to the documentation.. features that aren't documented
>are no good.

Easily done...

<hr>
<h2><a name="deletefiles">Deletefiles</a></h2>
<h3>Description</h3>
<p>Deletes all files from the specified directory and its sub-directories.</p>
<p>It is possible to refine the set of files that are being deleted. This
can be
done with the <i>includes</i>, <i>excludes</i> and <i>defaultexcludes</i>
attributes. With the <i>includes</i> attribute you specify the files you
want to
have included in the deletion process by using patterns. The <i>exclude</i>
attribute is used to specify
the files you want to have excluded from the deletion process. This is also
done with patterns. And
finally with the <i>defaultexcludes</i> attribute, you can specify whether you
want to use default exclusions or not. See the section on <a
href="#directorybasedtasks">directory based tasks</a>, on how the
inclusion/exclusion of files works, and how to write patterns. The patterns
are
relative to the <i>deldir</i> directory.</p>
<h3>Parameters</h3>
<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">deldir</td>
    <td valign="top">The directory to delete files from.</td>
    <td valign="top" align="center">Yes</td>
  </tr>
  <tr>
    <td valign="top">includes</td>
    <td valign="top">Comma separated list of patterns of files that must be
      deleted. All files are in the current directory 
      and any sub-directories are deleted when omitted.</td>
    <td valign="top" align="center">No</td>
  </tr>
  <tr>
    <td valign="top">excludes</td>
    <td valign="top">Comma separated list of patterns of files that must be
      excluded from the deletion list. No files (except default excludes)
are excluded when omitted.</td>
    <td valign="top" align="center">No</td>
  </tr>
  <tr>
    <td valign="top">defaultexcludes</td>
    <td valign="top">Indicates whether default excludes should be used or not
      (&quot;yes&quot;/&quot;no&quot;). Default excludes are used when
omitted.</td>
    <td valign="top" align="center">No</td>
  </tr>
  <tr>
    <td valign="top">verbose</td>
    <td valign="top">Show name of each deleted file
(&quot;true&quot;/&quot;false&quot;). Default is "false" when omitted.</td>
    <td align="center" valign="top">No</td>
  </tr>
</table>
<h3>Examples</h3>
<pre>  &lt;deletefiles deldir=&quot;lib&quot; /&gt;</pre>
<p>deletes all files in the <code>/lib</code> directory.</p>
<pre>  &lt;deletefiles deldir=&quot;.&quot;
               include=&quot;**/*.bak&quot;
  /&gt;
</pre>
<p>deletes all files with the extension &quot;<code>.bak</code>&quot
from
the current directory 
and any sub-directories.</p>

----------------------------------------------------------------------------
       Tom Dimock  ----  Cornell University  ----  tad1@cornell.edu
"There go my people.  I must follow them, for I am their leader."  M. Gandhi

Mime
View raw message