ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From adammurd...@apache.org
Subject cvs commit: jakarta-ant/proposal/myrmidon/src/xdocs buildfile.xml todo.xml vfs.xml
Date Sun, 03 Mar 2002 08:32:28 GMT
adammurdoch    02/03/03 00:32:28

  Modified:    proposal/myrmidon/docs buildfile.html todo.html vfs.html
               proposal/myrmidon/src/xdocs buildfile.xml todo.xml vfs.xml
  Added:       proposal/myrmidon/docs task.html
  Log:
  Document the new conditions.
  More todo list updates.
  
  Revision  Changes    Path
  1.2       +52 -146   jakarta-ant/proposal/myrmidon/docs/buildfile.html
  
  Index: buildfile.html
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/proposal/myrmidon/docs/buildfile.html,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- buildfile.html	2 Mar 2002 01:53:59 -0000	1.1
  +++ buildfile.html	3 Mar 2002 08:32:28 -0000	1.2
  @@ -613,153 +613,59 @@
       <tr><td>
         <blockquote>
                           <p>
  -The following table lists some of the current set of tasks.  You can find
  -example usages of these tasks in the sample project file
  -<code>src/make/sample.ant</code>.
  +Listed below are some of the current set of tasks.  You can find example
  +usages of these tasks in the sample project file <code>src/make/sample.ant</code>.
   </p>
  -                                  <table>
  -              <tr>
  -                  <td bgcolor="#039acc" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          Task
  -        </font>
  -  </td>
  -                      <td bgcolor="#039acc" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          Description
  -        </font>
  -  </td>
  -      </tr>
  -                  <tr>
  -                  <td bgcolor="#a0ddf0" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          fail
  -        </font>
  -  </td>
  -                      <td bgcolor="#a0ddf0" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          Causes the build to fail.
  -        </font>
  -  </td>
  -      </tr>
  -                  <tr>
  -                  <td bgcolor="#a0ddf0" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          if
  -        </font>
  -  </td>
  -                      <td bgcolor="#a0ddf0" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          Conditionally executes a set of tasks.
  -        </font>
  -  </td>
  -      </tr>
  -                  <tr>
  -                  <td bgcolor="#a0ddf0" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          load-properties
  -        </font>
  -  </td>
  -                      <td bgcolor="#a0ddf0" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          Loads a set of properties from a file.
  -        </font>
  -  </td>
  -      </tr>
  -                  <tr>
  -                  <td bgcolor="#a0ddf0" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          log
  -        </font>
  -  </td>
  -                      <td bgcolor="#a0ddf0" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          Writes a log message.
  -        </font>
  -  </td>
  -      </tr>
  -                  <tr>
  -                  <td bgcolor="#a0ddf0" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          property
  -        </font>
  -  </td>
  -                      <td bgcolor="#a0ddf0" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          Sets a property.
  -        </font>
  -  </td>
  -      </tr>
  -                  <tr>
  -                  <td bgcolor="#a0ddf0" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          try-catch
  -        </font>
  -  </td>
  -                      <td bgcolor="#a0ddf0" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          Runs a set of tasks, with a provided error and clean-up handler.
  -        </font>
  -  </td>
  -      </tr>
  -                  <tr>
  -                  <td bgcolor="#a0ddf0" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          converter-def
  -        </font>
  -  </td>
  -                      <td bgcolor="#a0ddf0" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          Register a type converter.  These are used when configuring a task
  -        or data-type from attributes.
  -        </font>
  -  </td>
  -      </tr>
  -                  <tr>
  -                  <td bgcolor="#a0ddf0" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          type-def
  -        </font>
  -  </td>
  -                      <td bgcolor="#a0ddf0" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          Register a task or data-type.
  -        </font>
  -  </td>
  -      </tr>
  -                  <tr>
  -                  <td bgcolor="#a0ddf0" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          import
  -        </font>
  -  </td>
  -                      <td bgcolor="#a0ddf0" colspan="" rowspan="" 
  -      valign="top" align="left">
  -    <font color="#000000" size="-1" face="arial,helvetica,sanserif">
  -          Register the contents of an antlib.
  -        </font>
  -  </td>
  -      </tr>
  -        </table>
  +                                <h3><code>&lt;condition&gt;</code></h3>
  +                                <p>Sets a property if a particular condition is true.
 See
  +<a href="#Conditions">Conditions</a> for a list of available conditions.</p>
  +                                <h3><code>&lt;fail&gt;</code></h3>
  +                                <p>Causes the build to fail.</p>
  +                                <h3><code>&lt;if&gt;</code></h3>
  +                                <p>Conditionally executes a set of tasks.</p>
  +                                <h3><code>&lt;load-properties&gt;</code></h3>
  +                                <p>Loads a set of properties from a file.</p>
  +                                <h3><code>&lt;log&gt;</code></h3>
  +                                <p>Writes a log message.</p>
  +                                <h3><code>&lt;property&gt;</code></h3>
  +                                <p>Sets a property.</p>
  +                                <h3><code>&lt;try-catch&gt;</code></h3>
  +                                <p>Runs a set of tasks, with a provided error and
clean-up handler.</p>
  +                                <h3><code>&lt;converter-def&gt;</code></h3>
  +                                <p>Register a type converter.  These are used when
configuring a task
  +or data-type from attributes.</p>
  +                                <h3><code>&lt;type-def&gt;</code></h3>
  +                                <p>Register a task or data-type.</p>
  +                                <h3><code>&lt;import&gt;</code></h3>
  +                                <p>Register the contents of an antlib.</p>
  +                    </blockquote>
  +    </td></tr>
  +  </table>
  +        <table border="0" cellspacing="0" cellpadding="2" width="100%">
  +    <tr><td bgcolor="#525D76">
  +      <font color="#ffffff" face="arial,helvetica,sanserif">
  +        <a name="Conditions"><strong>Conditions</strong></a>
  +      </font>
  +    </td></tr>
  +    <tr><td>
  +      <blockquote>
  +                        <p>The following conditions are available </p>
  +                                <h3><code>&lt;and&gt;</code></h3>
  +                                <p>Evaluates a set of nested conditions, and AND
them together.  Evaluation is
  +lazy.  An empty <code>&lt;and&gt;</code> condition evaluates to true.</p>
  +                                <h3><code>&lt;available&gt;</code></h3>
  +                                <p>Tests if a particular class or resource is available.</p>
  +                                <h3><code>&lt;file-test&gt;</code></h3>
  +                                <p>Tests a file against a set of <a href="vfs.html#File
Selectors">file selectors</a>.</p>
  +                                <h3><code>&lt;is-set&gt;</code></h3>
  +                                <p>Tests whether a proeprty is set, and not set to
'false'.</p>
  +                                <h3><code>&lt;or&gt;</code></h3>
  +                                <p>Evaluates a set of nested conditions, and OR them
together.  Evaluation is
  +lazy.  An empty <code>&lt;or&gt;</code> evaluates to true.</p>
  +                                <h3><code>&lt;os&gt;</code></h3>
  +                                <p>Tests which operating system the build is running
on.</p>
  +                                <h3><code>&lt;not&gt;</code></h3>
  +                                <p>Negates a nested condition.</p>
                       </blockquote>
       </td></tr>
     </table>
  
  
  
  1.5       +33 -11    jakarta-ant/proposal/myrmidon/docs/todo.html
  
  Index: todo.html
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/proposal/myrmidon/docs/todo.html,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- todo.html	2 Mar 2002 03:00:56 -0000	1.4
  +++ todo.html	3 Mar 2002 08:32:28 -0000	1.5
  @@ -159,12 +159,15 @@
                           <li>Add 'defaultexcludes' to <code>DefaultFileSet</code>.
 Also add a
                           file selector implementation that matches everything except the
default
                           excludes.</li>
  -                        <li>Add a condition -&gt; file selector adaptor, so that
arbitrary conditions
  -                        can be used to select files.</li>
                           <li>Add a name selector that loads patterns from a file.</li>
                           <li>Add more selector implementations: size and last-modified
comparisons,
                           checksum comparison, byte-wise content comparison.</li>
                       </ul></li>
  +                    <li>File conditions:
  +                    <ul>
  +                        <li>Add more condition implementations that perform checks
on files.
  +                        One that searches a path for a file would be useful.</li>
  +                    </ul></li>
                       <li>File Name Mappers:
                       <ul>
                           <li>Add a file name mapper interface, and port the current
Mapper
  @@ -190,15 +193,7 @@
                           an antlib, an installed extension, or the system classes of another
JVM
                           for cross-compiling).</li>
                       </ul></li>
  -                    <li>File Filters:
  -                    <ul>
  -                        <li>Add a file filter interface, and use it in the copy task.</li>
  -                        <li>Add a filter implementation that applies the token replacement
that
  -                        the old copy task provides.</li>
  -                        <li>Add a filter that does cr/lf translation.</li>
  -                        <li>Add a gzip/gunzip filter.</li>
  -                        <li>Add a filter that applies character set encode/decode.</li>
  -                    </ul></li>
  +                    <li>Port across the Ant 1 file filter proposal, once it is complete.</li>
                       <li>Copy task:
                       <ul>
                           <li>Implement 'preservelastmodified', 'overwrite', and 'includeemptydirs'.</li>
  @@ -248,6 +243,27 @@
                                     <table border="0" cellspacing="0" cellpadding="2"
width="100%">
       <tr><td bgcolor="#828DA6">
         <font color="#ffffff" face="arial,helvetica,sanserif">
  +        <a name="Scripting"><strong>Scripting</strong></a>
  +      </font>
  +    </td></tr>
  +    <tr><td>
  +      <blockquote>
  +                        <p>Add the ability to extend Ant using languages other than
  +                Java:</p>
  +                                <ul>
  +                    <li>Define a task using a scripting language such as Javascript.</li>
  +                    <li>Use Rhino's ability to implement Java interfaces, to
  +                    implement and define types, such as FileSelector, or
  +                    Condition.</li>
  +                    <li>Define a task using template.</li>
  +                    <li>Add some lightweight scripting tasks.</li>
  +                </ul>
  +                    </blockquote>
  +    </td></tr>
  +  </table>
  +                                  <table border="0" cellspacing="0" cellpadding="2"
width="100%">
  +    <tr><td bgcolor="#828DA6">
  +      <font color="#ffffff" face="arial,helvetica,sanserif">
           <a name="Documentation"><strong>Documentation</strong></a>
         </font>
       </td></tr>
  @@ -309,6 +325,12 @@
                       <li>Detect duplicate type names.</li>
                       <li>Add fully qualified type names, based on antlib name and
type shorthand name.
                       Allow these to be used in build files in addition to the shorthand
names.</li>
  +                    <li>Move the <code>&lt;http&gt;</code> and
<code>&lt;socket&gt;</code>
  +                    conditions to an antlib.  Need to resolve how these will be passed
a logger.</li>
  +                    <li>Make the <code>&lt;uptodate&gt;</code>
task a condition, and move to
  +                    an antlib.</li>
  +                    <li>Split up <code>&lt;is-set&gt;</code>
condition into is-set and is-true conditions.</li>
  +                    <li>Allow the <code>&lt;if&gt;</code> task
to take any condition implementation.</li>
                       <li>Unit tests.</li>
                   </ul>
                       </blockquote>
  
  
  
  1.3       +5 -1      jakarta-ant/proposal/myrmidon/docs/vfs.html
  
  Index: vfs.html
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/proposal/myrmidon/docs/vfs.html,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- vfs.html	2 Mar 2002 03:00:56 -0000	1.2
  +++ vfs.html	3 Mar 2002 08:32:28 -0000	1.3
  @@ -367,9 +367,13 @@
                                   <h3><code>&lt;basename&gt;</code></h3>
                                   <p>Selects files whose base name matches an Ant 1
style pattern, or a regular
                   expression.</p>
  +                                <h3><code>&lt;condition&gt;</code></h3>
  +                                <p>Takes a set of <a href="buildfile.html#Conditions">conditions</a>.
 If
  +                the conditions evaluate to true, then select every file.  Otherwise,
  +                select no files.</p>
                                   <h3><code>&lt;exists&gt;</code></h3>
                                   <p>Selects files that exist.</p>
  -                                <h3><code>&lt;is-empty&gt;</code></h3>
  +                                <h3><code>&lt;is-empty-folder&gt;</code></h3>
                                   <p>Selects empty folders, that is, folders that have
no children.</p>
                                   <h3><code>&lt;is-folder&gt;</code></h3>
                                   <p>Selects folders, does not select regular files.</p>
  
  
  
  1.1                  jakarta-ant/proposal/myrmidon/docs/task.html
  
  Index: task.html
  ===================================================================
  <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  
  <!-- Content Stylesheet for Site -->
  
      
  <!-- start the processing -->
      <html>
      <head>
        <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"/>
    
                        <meta name="author" value="Peter Donald">
    <meta name="email" value="peter@apache.org">
          
        <title>Apache Myrmidon - Writing a task</title>
      </head>
    
      <body bgcolor="#ffffff" text="#000000" link="#525D76">    
        <table border="0" width="100%" cellspacing="0">
          <!-- TOP IMAGE -->
          <tr>
            <td>      <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>
    </td>
            <td valign="bottom"><div align="right"><b><font size="+3"
color="#525D76">Apache Myrmidon</font></b></div></td>
          </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">
                  <p><strong>Myrmidon</strong></p>
      <ul>
            <li>      <a href="./index.html">Introduction</a>
    </li>
            <li>      <a href="./getinvolved.html">Get Involved</a>
    </li>
            <li>      <a href="./user.html">Building Myrmidon</a>
    </li>
            <li>      <a href="./todo.html">Todo List</a>
    </li>
          </ul>
        <p><strong>User Guide</strong></p>
      <ul>
            <li>      <a href="./buildfile.html">Build file</a>
    </li>
            <li>      <a href="./vfs.html">Virtual File System</a>
    </li>
          </ul>
        <p><strong>Extending Ant</strong></p>
      <ul>
            <li>      <a href="./task.html">Task Writers HOWTO</a>
    </li>
            <li>      <a href="./classloader.html">ClassLoader HOWTO</a>
    </li>
            <li>      <a href="./librarys.html">Library HOWTO</a>
    </li>
          </ul>
        <p><strong>Container Design</strong></p>
      <ul>
          </ul>
              </td>
            <td align="left" valign="top">
          <table border="0" cellspacing="0" cellpadding="2" width="100%">
      <tr><td bgcolor="#525D76">
        <font color="#ffffff" face="arial,helvetica,sanserif">
          <a name="Writing a Task"><strong>Writing a Task</strong></a>
        </font>
      </td></tr>
      <tr><td>
        <blockquote>
                          <p>In ant1 it was very easy to write your own task. In Ant2
we plan 
  to make it even easier. To write a basic task simply follow the following
  formula.</p>
                                  <ol>
    <li>
      Create a Java class that extends 
      <code>org.apache.myrmidon.api.AbstractTask</code>
    </li>
    <li>
      For each attribute, write a setter method. The setter method 
      must be a public void method that takes a single argument. The name 
      of the method must begin with "set", followed by the attribute name, with 
      the first character of the name in uppercase, and the rest in lowercase. 
      The type of the attribute can be:
      <ul>
        <li>String</li>
        <li>
          Any primitive type - they are converted for you from their 
          String-representation in the buildfile
        </li>
        <li>
          File - the string representation will be interpreted relative to 
          the project's basedir.
        </li>
      </ul>
    </li>
    <li>
      For each nested element create a public void method that takes a single 
      argument. The name of the method must begin with "add", followed by the 
      attribute name, with the first character of the name in uppercase, and 
      the rest in lowercase. The type of the parameter is an object with a 
      no-arguement constructor. It is configured in exactly the same was a 
      task is configured (via setters and adders) and then added to the task.
    </li>
    <li>
      Write a public void method named "execute" with no arguments that 
      throws a TaskException. This is the method called to do the 
      actual work of the task.
    </li>
  </ol>
                                    <table border="0" cellspacing="0" cellpadding="2" width="100%">
      <tr><td bgcolor="#828DA6">
        <font color="#ffffff" face="arial,helvetica,sanserif">
          <a name="A Basic Example"><strong>A Basic Example</strong></a>
        </font>
      </td></tr>
      <tr><td>
        <blockquote>
                          <p>So a basic task that has one attribute named "message"
and just prints 
  out this message is as simple as;</p>
                                    <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>
  package org.realityforge.tasks;
  
  import org.apache.myrmidon.api.AbstractTask;
  import org.apache.myrmidon.api.TaskException;
  
  public class SystemOutPrinterTask 
      extends Task 
  {
      private String m_message;
  
      // The setter for the &quot;message&quot; attribute
      public void setMessage( final String message )
      {
          m_message = message;
      }
  
      // The method executing the task
      public void execute() 
          throws TaskException 
      {
          System.out.println( m_message );
      }
  }
  </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>
                                  <p>To use this task you <em>could</em>
create a library but instead we will 
  just use &lt;taskdef&gt; to define the task. An example usage would be;</p>
                                    <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>
  
  
  &lt;?xml version=&quot;1.0&quot;?&gt;
  
  &lt;project version=&quot;2.0&quot;&gt;
  
    &lt;target name=&quot;main&quot;&gt;
      &lt;taskdef name=&quot;printer&quot; 
               classname=&quot;org.realityforge.tasks.SystemOutPrinterTask&quot;
               classpath=&quot;build/classes&quot;/&gt;
  
      &lt;printer message=&quot;Hello World!&quot;/&gt;
    &lt;/target&gt;
  &lt;/project&gt;
  
  
  </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>
                      </blockquote>
      </td></tr>
    </table>
                      </blockquote>
      </td></tr>
    </table>
                </td>
          </tr>
  
          <!-- FOOTER -->
          <tr><td colspan="2">
            <hr noshade="" size="1"/>
          </td></tr>
          <tr><td colspan="2">
            <div align="center"><font color="#525D76" size="-1"><em>
            Copyright &#169; 2000-2002, Apache Software Foundation
            </em></font></div>
          </td></tr>
        </table>
      </body>
    </html>
  <!-- end the processing -->
  
  
  
  
  
  
  
  1.2       +64 -43    jakarta-ant/proposal/myrmidon/src/xdocs/buildfile.xml
  
  Index: buildfile.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/proposal/myrmidon/src/xdocs/buildfile.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- buildfile.xml	2 Mar 2002 01:35:52 -0000	1.1
  +++ buildfile.xml	3 Mar 2002 08:32:28 -0000	1.2
  @@ -206,53 +206,74 @@
   <section name="Tasks">
   
   <p>
  -The following table lists some of the current set of tasks.  You can find
  -example usages of these tasks in the sample project file
  -<code>src/make/sample.ant</code>.
  +Listed below are some of the current set of tasks.  You can find example
  +usages of these tasks in the sample project file <code>src/make/sample.ant</code>.
   </p>
   
  -<table>
  -    <tr><th>Task</th><th>Description</th></tr>
  -    <tr>
  -        <td>fail</td>
  -        <td>Causes the build to fail.</td>
  -    </tr>
  -    <tr>
  -        <td>if</td>
  -        <td>Conditionally executes a set of tasks.</td>
  -    </tr>
  -    <tr>
  -        <td>load-properties</td>
  -        <td>Loads a set of properties from a file.</td>
  -    </tr>
  -    <tr>
  -        <td>log</td>
  -        <td>Writes a log message.</td>
  -    </tr>
  -    <tr>
  -        <td>property</td>
  -        <td>Sets a property.</td>
  -    </tr>
  -    <tr>
  -        <td>try-catch</td>
  -        <td>Runs a set of tasks, with a provided error and clean-up handler.</td>
  -    </tr>
  -    <tr>
  -        <td>converter-def</td>
  -        <td>Register a type converter.  These are used when configuring a task
  -        or data-type from attributes.</td>
  -    </tr>
  -    <tr>
  -        <td>type-def</td>
  -        <td>Register a task or data-type.</td>
  -    </tr>
  -    <tr>
  -        <td>import</td>
  -        <td>Register the contents of an antlib.</td>
  -    </tr>
  -</table>
  +<h3><code>&lt;condition&gt;</code></h3>
  +
  +<p>Sets a property if a particular condition is true.  See
  +<a href="#Conditions">Conditions</a> for a list of available conditions.</p>
  +
  +<h3><code>&lt;fail&gt;</code></h3>
  +<p>Causes the build to fail.</p>
  +
  +<h3><code>&lt;if&gt;</code></h3>
  +<p>Conditionally executes a set of tasks.</p>
  +
  +<h3><code>&lt;load-properties&gt;</code></h3>
  +<p>Loads a set of properties from a file.</p>
  +
  +<h3><code>&lt;log&gt;</code></h3>
  +<p>Writes a log message.</p>
  +
  +<h3><code>&lt;property&gt;</code></h3>
  +<p>Sets a property.</p>
  +
  +<h3><code>&lt;try-catch&gt;</code></h3>
  +<p>Runs a set of tasks, with a provided error and clean-up handler.</p>
  +
  +<h3><code>&lt;converter-def&gt;</code></h3>
  +<p>Register a type converter.  These are used when configuring a task
  +or data-type from attributes.</p>
  +
  +<h3><code>&lt;type-def&gt;</code></h3>
  +<p>Register a task or data-type.</p>
  +
  +<h3><code>&lt;import&gt;</code></h3>
  +<p>Register the contents of an antlib.</p>
  +
  +</section>
  +
  +<section name="Conditions">
  +
  +<p>The following conditions are available </p>
  +
  +<h3><code>&lt;and&gt;</code></h3>
  +<p>Evaluates a set of nested conditions, and AND them together.  Evaluation is
  +lazy.  An empty <code>&lt;and&gt;</code> condition evaluates to true.</p>
  +
  +<h3><code>&lt;available&gt;</code></h3>
  +<p>Tests if a particular class or resource is available.</p>
  +
  +<h3><code>&lt;file-test&gt;</code></h3>
  +<p>Tests a file against a set of <a href="vfs.html#File Selectors">file selectors</a>.</p>
  +
  +<h3><code>&lt;is-set&gt;</code></h3>
  +<p>Tests whether a proeprty is set, and not set to 'false'.</p>
  +
  +<h3><code>&lt;or&gt;</code></h3>
  +<p>Evaluates a set of nested conditions, and OR them together.  Evaluation is
  +lazy.  An empty <code>&lt;or&gt;</code> evaluates to true.</p>
  +
  +<h3><code>&lt;os&gt;</code></h3>
  +<p>Tests which operating system the build is running on.</p>
  +
  +<h3><code>&lt;not&gt;</code></h3>
  +<p>Negates a nested condition.</p>
   
   </section>
  +
   </body>
   
   </document>
  
  
  
  1.5       +25 -11    jakarta-ant/proposal/myrmidon/src/xdocs/todo.xml
  
  Index: todo.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/proposal/myrmidon/src/xdocs/todo.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- todo.xml	2 Mar 2002 03:00:56 -0000	1.4
  +++ todo.xml	3 Mar 2002 08:32:28 -0000	1.5
  @@ -74,12 +74,15 @@
                           <li>Add 'defaultexcludes' to <code>DefaultFileSet</code>.
 Also add a
                           file selector implementation that matches everything except the
default
                           excludes.</li>
  -                        <li>Add a condition -> file selector adaptor, so that
arbitrary conditions
  -                        can be used to select files.</li>
                           <li>Add a name selector that loads patterns from a file.</li>
                           <li>Add more selector implementations: size and last-modified
comparisons,
                           checksum comparison, byte-wise content comparison.</li>
                       </ul></li>
  +                    <li>File conditions:
  +                    <ul>
  +                        <li>Add more condition implementations that perform checks
on files.
  +                        One that searches a path for a file would be useful.</li>
  +                    </ul></li>
                       <li>File Name Mappers:
                       <ul>
                           <li>Add a file name mapper interface, and port the current
Mapper
  @@ -105,15 +108,7 @@
                           an antlib, an installed extension, or the system classes of another
JVM
                           for cross-compiling).</li>
                       </ul></li>
  -                    <li>File Filters:
  -                    <ul>
  -                        <li>Add a file filter interface, and use it in the copy task.</li>
  -                        <li>Add a filter implementation that applies the token replacement
that
  -                        the old copy task provides.</li>
  -                        <li>Add a filter that does cr/lf translation.</li>
  -                        <li>Add a gzip/gunzip filter.</li>
  -                        <li>Add a filter that applies character set encode/decode.</li>
  -                    </ul></li>
  +                    <li>Port across the Ant 1 file filter proposal, once it is complete.</li>
                       <li>Copy task:
                       <ul>
                           <li>Implement 'preservelastmodified', 'overwrite', and 'includeemptydirs'.</li>
  @@ -155,6 +150,19 @@
   
               </subsection>
   
  +            <subsection name="Scripting">
  +                <p>Add the ability to extend Ant using languages other than
  +                Java:</p>
  +                <ul>
  +                    <li>Define a task using a scripting language such as Javascript.</li>
  +                    <li>Use Rhino's ability to implement Java interfaces, to
  +                    implement and define types, such as FileSelector, or
  +                    Condition.</li>
  +                    <li>Define a task using template.</li>
  +                    <li>Add some lightweight scripting tasks.</li>
  +                </ul>
  +            </subsection>
  +
               <subsection name="Documentation">
   
                   <p>Everyone loves writing documentation, and so a goal for Ant 2
is to
  @@ -209,6 +217,12 @@
                       <li>Detect duplicate type names.</li>
                       <li>Add fully qualified type names, based on antlib name and
type shorthand name.
                       Allow these to be used in build files in addition to the shorthand
names.</li>
  +                    <li>Move the <code>&lt;http&gt;</code> and
<code>&lt;socket&gt;</code>
  +                    conditions to an antlib.  Need to resolve how these will be passed
a logger.</li>
  +                    <li>Make the <code>&lt;uptodate&gt;</code>
task a condition, and move to
  +                    an antlib.</li>
  +                    <li>Split up <code>&lt;is-set&gt;</code>
condition into is-set and is-true conditions.</li>
  +                    <li>Allow the <code>&lt;if&gt;</code> task
to take any condition implementation.</li>
                       <li>Unit tests.</li>
                   </ul>
   
  
  
  
  1.4       +6 -0      jakarta-ant/proposal/myrmidon/src/xdocs/vfs.xml
  
  Index: vfs.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/proposal/myrmidon/src/xdocs/vfs.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- vfs.xml	3 Mar 2002 02:28:17 -0000	1.3
  +++ vfs.xml	3 Mar 2002 08:32:28 -0000	1.4
  @@ -163,6 +163,12 @@
                   <p>Selects files whose base name matches an Ant 1 style pattern,
or a regular
                   expression.</p>
   
  +                <h3><code>&lt;condition&gt;</code></h3>
  +
  +                <p>Takes a set of <a href="buildfile.html#Conditions">conditions</a>.
 If
  +                the conditions evaluate to true, then select every file.  Otherwise,
  +                select no files.</p>
  +
                   <h3><code>&lt;exists&gt;</code></h3>
   
                   <p>Selects files that exist.</p>
  
  
  

--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message