| 1 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> |
| 2 | <html> |
| 3 | <head> |
| 4 | <title>Ant-Contrib Tasks</title> |
| 5 | </head> |
| 6 | |
| 7 | <body> |
| 8 | <h1>Ant-Contrib Tasks</h1> |
| 9 | |
| 10 | <h2>Contents</h2> |
| 11 | |
| 12 | <ul> |
| 13 | <li><a href="#intro">What's this?</a></li> |
| 14 | <li><a href="#install">Installation</a></li> |
| 15 | <li><a href="tasks/index.html">Tasks</a></li> |
| 16 | </ul> |
| 17 | |
| 18 | <h2><a name="intro">What's this?</a></h2> |
| 19 | |
| 20 | <p>The Ant-Contrib project is a collection of tasks (and at one |
| 21 | point maybe types and other tools) for <a |
| 22 | href="http://ant.apache.org/">Apache Ant</a>.</p> |
| 23 | |
| 24 | <p>This Software is distributed under the <a |
| 25 | href="LICENSE.txt">Apache Software License</a>.</p> |
| 26 | |
| 27 | <h2><a name="install">Installation</a></h2> |
| 28 | |
| 29 | <p>First you must install Apache Ant itself, most of the |
| 30 | Ant-Contrib tasks require Ant 1.5 or higher to work properly, |
| 31 | however, there are some tasks, specifically <for> which |
| 32 | require Ant 1.6. You can download Ant <a |
| 33 | href="http://ant.apache.org/bindownload.cgi">from |
| 34 | Apache</a>.</p> |
| 35 | |
| 36 | <p>Then you need the Ant-Contrib tasks themselves. As there is no |
| 37 | release of these tasks yet, you have to build them from sources. |
| 38 | Fortunately this is easy, check out the sources (grab the |
| 39 | <code>ant-contrib</code> module from <a |
| 40 | href="http://sourceforge.net/cvs/?group_id=36177">CVS</a>), change |
| 41 | into the source directory of ant-contrib and type |
| 42 | <code>ant</code>. After Ant has completed, you'll find |
| 43 | <code>ant-contrib-version.jar</code> in the <code>lib</code> |
| 44 | subdirectory.</p> |
| 45 | |
| 46 | <p>You now have the choice:</p> |
| 47 | |
| 48 | <ol> |
| 49 | <li>Copy <code>ant-contrib-version.jar</code> to the |
| 50 | <code>lib</code> directory of your Ant installation, or on |
| 51 | your CLASSPATH environment variable. If you |
| 52 | want to use one of the tasks in your project, add the line |
| 53 | <pre> |
| 54 | <taskdef resource="net/sf/antcontrib/antlib.xml"/> |
| 55 | </pre> |
| 56 | to your build file.</li> |
| 57 | |
| 58 | <br /> |
| 59 | <br /> |
| 60 | |
| 61 | <li>Keep <code>ant-contrib-version.jar</code> in a separate |
| 62 | location. You now have to tell Ant explicitly where to find it |
| 63 | (say in <code>/usr/share/java/lib</code>): |
| 64 | <pre> |
| 65 | <taskdef resource="net/sf/antcontrib/antlib.xml"> |
| 66 | <classpath> |
| 67 | <pathelement location="/usr/share/java/lib/ant-contrib-version.jar"/> |
| 68 | </classpath> |
| 69 | </taskdef> |
| 70 | </pre> |
| 71 | </li> |
| 72 | |
| 73 | <li>If you would like to use run with Ant Version 1.5 you must use the |
| 74 | the .properties file instead. Keep in mind that some tasks will not |
| 75 | be available to you , such as the <for> task: |
| 76 | |
| 77 | <pre> |
| 78 | <taskdef resource="net/sf/antcontrib/antcontrib.properties"> |
| 79 | <classpath> |
| 80 | <pathelement location="/usr/share/java/lib/ant-contrib-version.jar"/> |
| 81 | </classpath> |
| 82 | </taskdef> |
| 83 | </pre> |
| 84 | |
| 85 | |
| 86 | <hr> |
| 87 | <p align="center">Copyright © 2002-2004 Ant-Contrib Project. All |
| 88 | rights Reserved.</p> |
| 89 | |
| 90 | </body> |
| 91 | </html> |