Added: ant/sandbox/antlibs/svn/trunk/build.xml URL: http://svn.apache.org/viewcvs/ant/sandbox/antlibs/svn/trunk/build.xml?view=auto&rev=161469 ============================================================================== --- ant/sandbox/antlibs/svn/trunk/build.xml (added) +++ ant/sandbox/antlibs/svn/trunk/build.xml Fri Apr 15 07:32:50 2005 @@ -0,0 +1,91 @@ +<?xml version="1.0"?> +<!-- + Copyright 2005 The Apache Software Foundation + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> +<project default="compile"> + + <target name="setup"> + <property name="build" value="build"/> + <property name="build.classes" value="${build}/classes"/> + <property name="build.testclasses" value="${build}/test-classes"/> + <property name="build.lib" value="${build}/lib"/> + <property name="jarname" value="${build.lib}/ant-svn.jar"/> + <mkdir dir="${build.classes}"/> + <mkdir dir="${build.testclasses}"/> + <mkdir dir="${build.lib}"/> + </target> + + <target name="compile" depends="setup"> + <javac + srcdir="src/main" + destdir="${build.classes}" + debug="true" + /> + </target> + + <target name="antlib" depends="compile"> + <copy todir="${build.classes}"> + <fileset dir="src/main" includes="**/antlib.xml"/> + </copy> + <jar + destfile="${jarname}" + basedir="${build.classes}" + /> + </target> + + <target name="setup-for-tests" depends="setup"> + <ant + antfile="../../../build.xml" + target="test-jar" + inheritall="false" + /> + </target> + + <target name="compile-tests" depends="setup-for-tests, antlib"> + <javac + srcdir="src/testcases" + destdir="${build.testclasses}" + debug="true" + > + <classpath> + <pathelement location="${jarname}"/> + <pathelement location="../../../build/lib/ant-testutil.jar"/> + </classpath> + </javac> + </target> + + <target name="test" depends="compile-tests"> + <junit + printsummary="false" + haltonfailure="false" + failureproperty="tests.failed" + filtertrace="false" + > + <classpath> + <pathelement location="${jarname}"/> + <pathelement location="../../../build/lib/ant-testutil.jar"/> + <pathelement location="${build.testclasses}"/> + </classpath> + + <batchtest> + <fileset dir="src/testcases"/> + </batchtest> + + <formatter type="plain" usefile="false"/> + </junit> + + <fail if="tests.failed">At least one test has failed.</fail> + </target> +</project> \ No newline at end of file
Propchange: ant/sandbox/antlibs/svn/trunk/build.xml ------------------------------------------------------------------------------ svn:eol-style = native Added: ant/sandbox/antlibs/svn/trunk/docs/changelog.html URL: http://svn.apache.org/viewcvs/ant/sandbox/antlibs/svn/trunk/docs/changelog.html?view=auto&rev=161469 ============================================================================== --- ant/sandbox/antlibs/svn/trunk/docs/changelog.html (added) +++ ant/sandbox/antlibs/svn/trunk/docs/changelog.html Fri Apr 15 07:32:50 2005 @@ -0,0 +1,217 @@ +<html> + +<head> +<meta http-equiv="Content-Language" content="en-us"> +<title>ChangeLog Task</title> +</head> + +<body> + +<h2><a name="changelog">ChangeLog</a></h2> +<h3>Description</h3> + +<p>Generates an XML-formatted report file of the change logs recorded +in a <a href="http://subversion.tigris.org/" +target="_top">Subversion</a> repository. </p> + +<p><b>Important:</b> This task needs "svn" on the path. If it isn't, +you will get an error (such as error 2 on windows). If +<code><svn></code> doesn't work, try to execute svn.exe from the +command line in the target directory in which you are working.</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 colspan="3">Attributes from parent <a href="svn.html">svn + task</a> which are meaningful here<br/> + </tr> + <tr> + <td valign="top">svnURL</td> + <td valign="top">the URL the subcommand should apply to.</td> + <td align="center" valign="top">No</td> + </tr> + <tr> + <td valign="top">dest</td> + <td valign="top">the directory where the checked out files are.</td> + <td align="center" valign="top">No, default is project's basedir.</td> + </tr> + <tr> + <td valign="top">failonerror</td> + <td valign="top">Stop the build process if the command exits with a + return code other than <code>0</code>. Defaults to false</td> + <td align="center" valign="top">No</td> + </tr> + <tr> + <td colspan="3">Specific attributes</td> + </tr> + <tr> + <td valign="top">dir</td> + <td valign="top">The directory from which to run the CVS <em>log</em> + command.</td> + <td align="center" valign="top">No; defaults to ${basedir}.</td> + </tr> + <tr> + <td valign="top">destfile</td> + <td valign="top">The file in which to write the change log report.</td> + <td align="center" valign="top">Yes</td> + </tr> + <tr> + <td valign="top">usersfile</td> + <td valign="top">Property file that contains name-value pairs mapping + user IDs and names that should be used in the report in place of + the user ID.</td> + <td align="center" valign="top">No</td> + </tr> + <tr> + <td valign="top">daysinpast</td> + <td valign="top">Sets the number of days into the past for which the + change log information should be retrieved.</td> + <td align="center" valign="top">No</td> + </tr> + <tr> + <td valign="top">start</td> + <td valign="top">The earliest revision/date from which change logs + are to be included in the report.</td> + <td align="center" valign="top">No</td> + </tr> + <tr> + <td valign="top">end</td> + <td valign="top">The latest revision/date to which change logs are to be + included in the report.</td> + <td align="center" valign="top">No</td> + </tr> +</table> + +<h3>Parameters specified as nested elements</h3> +<h4><a name="user">user</a></h4> + +<p>The nested <code><user></code> element allows you to specify +a mapping between a user ID as it appears on the Subversion server and +a name to include in the formatted report. Anytime the specified user +ID has made a change in the repository, the +<code><author></code> tag in the report file will include the +name specified in <code>displayname</code> rather than the user +ID.</p> + +<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">displayname</td> + <td valign="top">The name to be used in the Subversion change log + report.</td> + <td valign="top" align="center">Yes</td> + </tr> + <tr> + <td valign="top">userid</td> + <td valign="top">The userid of the person as it exists on the + Subversion server. + </td> + <td valign="top" align="center">Yes</td> + </tr> +</table> + + +<h3>Examples</h3> +<pre> <changelog dir="dve/network" + destfile="changelog.xml" + /></pre> + +<p>Generates a change log report for all the changes that have been made +under the <code>dve/network</code> directory. +It writes these changes into the file <code>changelog.xml</code>.</p> + +<pre> <changelog dir="dve/network" + destfile="changelog.xml" + daysinpast="10" + /></pre> + +<p>Generates a change log report for any changes that were made +under the <code>dve/network</code> directory in the past 10 days. +It writes these changes into the file <code>changelog.xml</code>.</p> + +<pre> <changelog dir="dve/network" + destfile="changelog.xml" + start="{2002-02-20}" + end="{2002-03-20}" + /></pre> + +<p>Generates a change log report for any changes that were made +between February 20, 2002 and March 20, 2002 +under the <code>dve/network</code> directory. +It writes these changes into the file <code>changelog.xml</code>.</p> + +<pre> <changelog dir="dve/network" + destfile="changelog.xml" + start="{2002-02-20}" + /></pre> + +<p>Generates a change log report for any changes that were made +after February 20, 2002 under the <code>dve/network</code> directory. +It writes these changes into the file <code>changelog.xml</code>.</p> + +<pre> <changelog dir="dve/network" + destfile="changelog.xml" + start="1000" + end="1500" + /></pre> + +<p>Generates a change log report for any changes that were made +between Subversion revisions 1000 and 1500 under the +<code>dve/network</code> directory. It writes these changes into the +file <code>changelog.xml</code>.</p> + +<pre> <changelog dir="dve/network" + destfile="changelog.xml"> + <user displayname="Esmerelda Weatherwax" userid="granny"/> + </changelog></pre> + +<p>Generates a change log report for all the changes that were made +under the <code>dve/network</code> directory, substituting the name +"Esmerelda Weatherwax" in the <code><author></code> tags +anytime it encounters a change made by the user ID "granny". +It writes these changes into the file <code>changelog.xml</code>.</p> + +<h4>Generate Report</h4> +<p>This antlib includes a basic XSLT stylesheet that you can use to +generate a HTML report based on the xml output. The following example +illustrates how to generate a HTML report from the XML report.</p> + +<pre> + <style in="changelog.xml" + out="changelog.html" + style="your-path-to/etc/changelog.xsl"> + <param name="title" expression="Jakarta BCEL ChangeLog"/> + <param name="repo" expression="http://svn.apache.org/repos/asf"/> + </style> +</pre> + +<h4>Sample Output</h4> +<pre> + <entry> + <date>2005-02-14</date> + <time>01:55</time> + <author><![CDATA[dbrosius]]></author> + <revision>153687</revision> + <path> + <name><![CDATA[/jakarta/bcel/trunk/src/java/org/apache/bcel/util/BCELifier.java]]></name> + <action>modified</action> + </path> + <message><![CDATA[Update BCELifier to handle the new method access flags (ACC_BRIDGE, ACC_VARARGS)]]></message> + </entry> +</pre> + +<hr><p align="center">Copyright © 2005 The Apache Software Foundation. All rights +Reserved.</p> + +</body> +</html> + Propchange: ant/sandbox/antlibs/svn/trunk/docs/changelog.html ------------------------------------------------------------------------------ svn:eol-style = native Added: ant/sandbox/antlibs/svn/trunk/docs/revisiondiff.html URL: http://svn.apache.org/viewcvs/ant/sandbox/antlibs/svn/trunk/docs/revisiondiff.html?view=auto&rev=161469 ============================================================================== --- ant/sandbox/antlibs/svn/trunk/docs/revisiondiff.html (added) +++ ant/sandbox/antlibs/svn/trunk/docs/revisiondiff.html Fri Apr 15 07:32:50 2005 @@ -0,0 +1,129 @@ +<html> +<head> +<meta http-equiv="Content-Language" content="en-us"> +<title>RevisionDiff Task</title> +</head> +<body> +<h2><a name="revisiondiff">RevisionDiff</a></h2> +<h3>Description</h3> + +<p>Generates an XML-formatted report file of the changes between two +revisions recorded in a <a href="http://subversion.tigris.org/" +target="_top">Subversion</a> repository. </p> + +<p><b>Important:</b> This task needs "svn" on the path. If it isn't, +you will get an error (such as error 2 on windows). If +<code><svn></code> doesn't work, try to execute +<code>svn.exe</code> from the command line in the target directory in +which you are working.</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">start</td> + <td valign="top">The earliest revision from which diffs are to be + included in the report.</td> + <td align="center" valign="top">Yes.</td> + </tr> + <tr> + <td valign="top">end</td> + <td valign="top">The latest revision from which diffs are to be + included in the report.</td> + <td align="center" valign="top">Yes.</td> + </tr> + <tr> + <td valign="top">destfile</td> + <td valign="top">The file in which to write the diff report.</td> + <td align="center" valign="top">Yes</td> + </tr> +</table> + +<h3>Parameters inherited from the <code>svn</code> task</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">svnURL</td> + <td valign="top">the svn URL to diff.</td> + <td align="center" valign="top">No</td> + </tr> + <tr> + <td valign="top">failonerror</td> + <td valign="top">Stop the buildprocess if the command exits with a + returncode other than 0. Defaults to false</td> + <td align="center" valign="top">No</td> + </tr> +</table> + +<h3>Examples</h3> +<pre> <revisiondiff + svnURL="http://svn.apache.org/repos/asf/jakarta/bcel/trunk" + destfile="diff.xml" + start="152904" + end="153682" + /></pre> + +<p>Generates a revisiondiff report for all the changes that have been +made in the <code>Apache BCEL</code> module between the revisions +<code>152904</code> and <code>153682</code>. It writes these changes +into the file <code>diff.xml</code>.</p> + +<pre> <revisiondiff + destfile="diff.xml" + package="ant" + start="{2002-01-01}" + end="{2002-02-01}" + dest="my-working-copy-of-BCEL" + /></pre> + +<p>Generates a diff report for all the changes that have been made in +the <code>Apache BCEL</code> module in january 2002. In this example +<code>svnURL</code> has not been set, it is assumed that +<code>my-working-copy-of-BCEL</code> contains a checked out copy of +the BCEL module. It writes these changes into the file +<code>diff.xml</code>.</p> + +<h4>Generate Report</h4> + +<p>This antlib includes a basic XSLT stylesheet that you can use to +generate a HTML report based on the xml output. The following example +illustrates how to generate a HTML report from the XML report.</p> + +<pre> + <style in="diff.xml" + out="diff.html" + style="your-path-to/etc/diff.xsl"> + <param name="title" expression="Jakarta BCEL diff"/> + <param name="repo" expression="http://svn.apache.org/repos/asf/jakarta/bcel/trunk"/> + </style> +</pre> + +<h4>(Shortened) Example Output</h4> +<pre> +<?xml version="1.0" encoding="UTF-8"?> +<revisiondiff start="153872" end="152873" svnurl="http://svn.apache.org/repos/asf/jakarta/bcel/trunk" > + <path> + <name><![CDATA[LICENSE.txt]]></name> + <action>modified</action> + </path> + <path> + <name><![CDATA[NOTICE.txt]]></name> + <action>deleted</action> + </path> +</revisiondiff> +</pre> + +<hr><p align="center">Copyright © 2005 The Apache Software Foundation. All rights +Reserved.</p> + +</body> +</html> + Propchange: ant/sandbox/antlibs/svn/trunk/docs/revisiondiff.html ------------------------------------------------------------------------------ svn:eol-style = native Added: ant/sandbox/antlibs/svn/trunk/docs/svn.html URL: http://svn.apache.org/viewcvs/ant/sandbox/antlibs/svn/trunk/docs/svn.html?view=auto&rev=161469 ============================================================================== --- ant/sandbox/antlibs/svn/trunk/docs/svn.html (added) +++ ant/sandbox/antlibs/svn/trunk/docs/svn.html Fri Apr 15 07:32:50 2005 @@ -0,0 +1,157 @@ +<html> + +<head> +<meta http-equiv="Content-Language" content="en-us"> +<title>Subversion Task</title> +<link rel="stylesheet" type="text/css" href="../stylesheets/antmanual.css"> +</head> + +<body> + +<h2><a name="svn">SVN</a></h2> +<h3>Description</h3> +<p>Handles packages/modules retrieved from a +<a href="http://subversion.tigris.org/" target="_top">Subversion</a> repository.</p> +<p><b>Important:</b> This task needs "<code>svn</code>" on the path. If it isn't, you will get +an error (such as error <code>2</code> on windows). If <code><svn></code> doesn't work, try to execute <code>svn.exe</code> +from the command line in the target directory in which you are working. +<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">subcommand</td> + <td valign="top">the SVN subcommand to execute.</td> + <td align="center" valign="top">No, default "checkout".</td> + </tr> + <tr> + <td valign="top">svnURL</td> + <td valign="top">the URL the subcommand should apply to.</td> + <td align="center" valign="top">No</td> + </tr> + <tr> + <td valign="top">dest</td> + <td valign="top">the directory where the checked out files should + be placed. Note that this is different from SVN's <code>-d</code> command line + switch as Ant will never shorten pathnames to avoid empty + directories.</td> + <td align="center" valign="top">No, default is project's basedir.</td> + </tr> + <tr> + <td valign="top">revision</td> + <td valign="top">the revision or date of the subcommand should apply to</td> + <td align="center" valign="top">No</td> + </tr> + <tr> + <td valign="top">quiet</td> + <td valign="top">suppress informational messages. This is the same as <code>--quiet</code> on the command line.</td> + <td align="center" valign="top">No, default "false"</td> + </tr> + <tr> + <td valign="top">verbose</td> + <td valign="top">Be verbose. This is the same as <code>--verbose</code> on the command line.</td> + <td align="center" valign="top">No, default "false"</td> + </tr> + <tr> + <td valign="top">dryrun</td> + <td valign="top">report only, don't change any files.</td> + <td align="center" valign="top">No, default to "false"</td> + </tr> + <tr> + <td valign="top">file</td> + <td valign="top">Uses the contents of the file passed as an + argument to this switch for the specified subcommand.</td> + <td align="center" valign="top">No.</td> + </tr> + <tr> + <td valign="top">force</td> + <td valign="top">Forces a particular command or operation to run.</td> + <td align="center" valign="top">No, defaults to false.</td> + </tr> + <tr> + <td valign="top">recursive</td> + <td valign="top">Makes a subcommand recurse into + subdirectories. Most subcommands recurse by default.</td> + <td align="center" valign="top">No.</td> + </tr> + <tr> + <td valign="top">targets</td> + <td valign="top">Tells Subversion to get the list of files that you wish to + operate on from the filename you provide instead of listing all + the files on the command line.</td> + <td align="center" valign="top">No.</td> + </tr> + <tr> + <td valign="top">output</td> + <td valign="top">the file to direct standard output from the command.</td> + <td align="center" valign="top">No, default output to ANT Log as <code>MSG_INFO</code>.</td> + </tr> + <tr> + <td valign="top">error</td> + <td valign="top">the file to direct standard error from the command.</td> + <td align="center" valign="top">No, default error to ANT Log as <code>MSG_WARN</code>.</td> + </tr> + <tr> + <td valign="top">append</td> + <td valign="top">whether to append output/error when redirecting to a file.</td> + <td align="center" valign="top">No, default to "false".</td> + </tr> + <tr> + <td valign="top">failonerror</td> + <td valign="top">Stop the build process if the command exits with a + return code other than <code>0</code>. Defaults to "false"</td> + <td align="center" valign="top">No</td> + </tr> +</table> +<h3>Examples</h3> +<pre> <svn svnURL="http://svn.apache.org/repos/asf/httpd/httpd/trunk/" + dest="${ws.dir}" + /></pre> +<p>checks out the URL +"http://svn.apache.org/repos/asf/httpd/httpd/trunk/" and +stores the files in "<code>${ws.dir}</code>".</p> +<pre> <svn dest="${ws.dir}" command="update"/></pre> +<p>updates the working copy that has previously been checked out into +"<code>${ws.dir}</code>".</p> + +<pre> <svn command="-q diff" output="patch.txt"/></pre> + +<p>silently (<code>-q</code>) creates a file called <code>patch.txt</code> which contains a unified diff which can be used as input to patch. +The equivalent, using <code><commandline></code> elements, is: +</p> +<pre> +<svn output="patch"> + <commandline> + <argument value="-q"/> + <argument value="diff"/> + </commandline> +</svn> +</pre> +or: +<pre> +<svn output="patch"> + <commandline> + <argument line="-q diff -u -N"/> + </commandline> +</svn> +</pre> +<p> +You may include as many <code><commandline></code> elements as you like. +Each will inherit the <code>failonerror</code> and other "global" parameters +from the <code><svn></code> element. +</p> + +<pre> <svn command="update"/></pre> +<p>Updates from the head of repository creating any new directories as necessary.</p> +<p>See <a href="http://svnbook.red-bean.com/en/1.1/ch09.html#svn-ch-9-sect-1" target="_top">Version Control with Subversion</a> for details, +specifically the <a href="http://svnbook.red-bean.com/en/1.1/ch09.html#svn-ch-9-sect-1" target="_top">The Subversion Command Line Client: svn</a></p> +<hr> +<p align="center">Copyright © 2005 The Apache Software +Foundation. All rights Reserved.</p> + +</body> +</html> + Propchange: ant/sandbox/antlibs/svn/trunk/docs/svn.html ------------------------------------------------------------------------------ svn:eol-style = native Added: ant/sandbox/antlibs/svn/trunk/docs/tagdiff.html URL: http://svn.apache.org/viewcvs/ant/sandbox/antlibs/svn/trunk/docs/tagdiff.html?view=auto&rev=161469 ============================================================================== --- ant/sandbox/antlibs/svn/trunk/docs/tagdiff.html (added) +++ ant/sandbox/antlibs/svn/trunk/docs/tagdiff.html Fri Apr 15 07:32:50 2005 @@ -0,0 +1,158 @@ +<html> +<head> +<meta http-equiv="Content-Language" content="en-us"> +<title>RevisionDiff Task</title> +</head> +<body> +<h2><a name="tagdiff">TagDiff</a></h2> +<h3>Description</h3> + +<p>Generates an XML-formatted report file of the changes between two +tags recorded in a <a href="http://subversion.tigris.org/" +target="_top">Subversion</a> repository. </p> + +<p><b>Important:</b> This task needs "svn" on the path. If it isn't, +you will get an error (such as error 2 on windows). If +<code><svn></code> doesn't work, try to execute +<code>svn.exe</code> from the command line in the target directory in +which you are working.</p> + +<p>This task assumes that your repository follows the best-practice +layout of</p> +<pre> +BASEURL + | + | + -----> trunk + -----> tags + | + | + ----------> tag1 + ----------> tag2 +</pre> + +<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">tag1</td> + <td valign="top">The first tag.</td> + <td align="center" valign="top">Yes.</td> + </tr> + <tr> + <td valign="top">tag2</td> + <td valign="top">The second tag.</td> + <td align="center" valign="top">No, defaults to "trunk/"</td> + </tr> + <tr> + <td valign="top">destfile</td> + <td valign="top">The file in which to write the diff report.</td> + <td align="center" valign="top">Yes</td> + </tr> + <tr> + <td valign="top">baseURL</td> + <td valign="top">The baseURL of the repository, used to calculate + the two URLs to compare.</td> + <td align="center" valign="top">Yes</td> + </tr> +</table> + +<h3>Parameters inherited from the <code>svn</code> task</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">failonerror</td> + <td valign="top">Stop the buildprocess if the command exits with a + returncode other than 0. Defaults to false</td> + <td align="center" valign="top">No</td> + </tr> +</table> + +<h3>Examples</h3> +<pre> + <tagdiff failonerror="true" + baseURL="http://svn.apache.org/repos/asf/jakarta/bcel/" + destfile="diff.xml" + tag1="initial" + tag2="BCEL_5_0" + /> +</pre> + +<p>Generates a tagdiff report for all the changes that have been +made in the <code>Apache BCEL</code> module between the tags +<code>initial</code> and <code>BCEL_5_0</code>. It writes these changes +into the file <code>diff.xml</code>.</p> + +<pre> + <tagdiff failonerror="true" + baseURL="http://svn.apache.org/repos/asf/jakarta/bcel/" + destfile="diff.xml" + tag1="BCEL_5_0" + tag2="trunk" + /> +</pre> + +<p>Generates a tagdiff report for all the changes that have been made +in the <code>Apache BCEL</code> module between the tag +<code>BCEL_5_0</code> and the <code>trunk</code>. It writes these +changes into the file <code>diff.xml</code>.</p> + +<pre> + <tagdiff failonerror="true" + baseURL="http://svn.apache.org/repos/asf/jakarta/bcel/" + destfile="diff.xml" + tag1="BCEL_5_0" + /> +</pre> + +<p>Does the same, using <code>trunk</code> as <code>tag2</code> +implicitly.</p> + +<h4>Generate Report</h4> + +<p>This antlib includes a basic XSLT stylesheet that you can use to +generate a HTML report based on the xml output. The following example +illustrates how to generate a HTML report from the XML report.</p> + +<pre> + <style in="diff.xml" + out="diff.html" + style="your-path-to/etc/diff.xsl"> + <param name="title" expression="Jakarta BCEL diff"/> + <param name="repo" expression="http://svn.apache.org/repos/asf/jakarta/bcel/trunk"/> + </style> +</pre> + +<h4>(Shortened) Example Output</h4> +<pre> +<?xml version="1.0" encoding="UTF-8"?> +<tagdiff tag1="BCEL_5_0" svnurl="http://svn.apache.org/repos/asf/jakarta/bcel/" > + <path> + <name><![CDATA[default.properties]]></name> + <action>added</action> + </path> + <path> + <name><![CDATA[xdocs/images/classloader.gif]]></name> + <action>modified</action> + </path> + <path> + <name><![CDATA[README]]></name> + <action>deleted</action> + </path> +</tagdiff> +</pre> + +<hr><p align="center">Copyright © 2005 The Apache Software Foundation. All rights +Reserved.</p> + +</body> +</html> + Propchange: ant/sandbox/antlibs/svn/trunk/docs/tagdiff.html ------------------------------------------------------------------------------ svn:eol-style = native Added: ant/sandbox/antlibs/svn/trunk/src/etc/changelog.xsl URL: http://svn.apache.org/viewcvs/ant/sandbox/antlibs/svn/trunk/src/etc/changelog.xsl?view=auto&rev=161469 ============================================================================== --- ant/sandbox/antlibs/svn/trunk/src/etc/changelog.xsl (added) +++ ant/sandbox/antlibs/svn/trunk/src/etc/changelog.xsl Fri Apr 15 07:32:50 2005 @@ -0,0 +1,137 @@ +<?xml version="1.0" encoding="ISO-8859-1"?> + +<xsl:stylesheet + xmlns:xsl='http://www.w3.org/1999/XSL/Transform' + version='1.0'> + +<!-- + Copyright 2005 The Apache Software Foundation + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +--> + <xsl:param name="title"/> + <xsl:param name="repo"/> + + <xsl:output method="html" indent="yes" encoding="US-ASCII" + doctype-public="-//W3C//DTD HTML 4.01//EN" + doctype-system="http://www.w3.org/TR/html401/strict.dtd"/> + + <!-- Copy standard document elements. Elements that + should be ignored must be filtered by apply-templates + tags. --> + <xsl:template match="*"> + <xsl:copy> + <xsl:copy-of select="attribute::*[. != '']"/> + <xsl:apply-templates/> + </xsl:copy> + </xsl:template> + + <xsl:template match="changelog"> + <html> + <head> + <title><xsl:value-of select="$title"/></title> + <style type="text/css"> + body, p { + font-family: Verdana, Arial, Helvetica, sans-serif; + font-size: 80%; + color: #000000; + background-color: #ffffff; + } + tr, td { + font-family: Verdana, Arial, Helvetica, sans-serif; + background: #eeeee0; + } + td { + padding-left: 20px; + } + .dateAndAuthor { + font-family: Verdana, Arial, Helvetica, sans-serif; + font-weight: bold; + text-align: left; + background: #a6caf0; + padding-left: 3px; + } + a { + color: #000000; + } + pre { + font-weight: bold; + } + </style> + </head> + <body> + <h1> + <a name="top"><xsl:value-of select="$title"/></a> + </h1> + <p style="text-align: right">Designed for use with <a href="http://ant.apache.org/">Apache Ant</a>.</p> + <hr/> + <table border="0" width="100%" cellspacing="1"> + + <xsl:apply-templates select=".//entry"> + <xsl:sort select="date" data-type="text" order="descending"/> + <xsl:sort select="time" data-type="text" order="descending"/> + </xsl:apply-templates> + + </table> + + </body> + </html> + </xsl:template> + + <xsl:template match="entry"> + <tr> + <td class="dateAndAuthor"> + <xsl:value-of select="date"/><xsl:text> </xsl:text><xsl:value-of select="time"/><xsl:text> </xsl:text><xsl:value-of select="author"/> + </td> + </tr> + <tr> + <td> + <pre> +<xsl:apply-templates select="message"/></pre> + <ul> + <xsl:apply-templates select="path"/> + </ul> + </td> + </tr> + </xsl:template> + + <xsl:template match="date"> + <i><xsl:value-of select="."/></i> + </xsl:template> + + <xsl:template match="time"> + <i><xsl:value-of select="."/></i> + </xsl:template> + + <xsl:template match="author"> + <i> + <xsl:value-of select="."/> + </i> + </xsl:template> + + <xsl:template match="path"> + <li> + <a> + <xsl:attribute name="href"><xsl:value-of select="$repo"/><xsl:value-of select="name"/></xsl:attribute><xsl:value-of select="$repo"/><xsl:value-of select="name"/></a> + (<xsl:value-of select="action"/>) + </li> + </xsl:template> + + <!-- Any elements within a message are processed, + so that we can preserve HTML tags. --> + <xsl:template match="message"> + <xsl:apply-templates/> + </xsl:template> + +</xsl:stylesheet> Propchange: ant/sandbox/antlibs/svn/trunk/src/etc/changelog.xsl ------------------------------------------------------------------------------ svn:eol-style = native Added: ant/sandbox/antlibs/svn/trunk/src/etc/diff.xsl URL: http://svn.apache.org/viewcvs/ant/sandbox/antlibs/svn/trunk/src/etc/diff.xsl?view=auto&rev=161469 ============================================================================== --- ant/sandbox/antlibs/svn/trunk/src/etc/diff.xsl (added) +++ ant/sandbox/antlibs/svn/trunk/src/etc/diff.xsl Fri Apr 15 07:32:50 2005 @@ -0,0 +1,140 @@ +<!-- + Copyright 2005 The Apache Software Foundation + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + +--> +<xsl:stylesheet + xmlns:xsl="http://www.w3.org/1999/XSL/Transform" + version="1.0"> + <xsl:param name="title"/> + <xsl:param name="repo"/> + + <xsl:output method="html" indent="yes"/> + + <!-- Copy standard document elements. Elements that + should be ignored must be filtered by apply-templates + tags. --> + <xsl:template match="*"> + <xsl:copy> + <xsl:copy-of select="attribute::*[. != '']"/> + <xsl:apply-templates/> + </xsl:copy> + </xsl:template> + + <xsl:template match="revisiondiff|tagdiff"> + <HTML> + <HEAD> + <TITLE><xsl:value-of select="$title"/></TITLE> + </HEAD> + <BODY link="#000000" alink="#000000" vlink="#000000" text="#000000"> + <style type="text/css"> + body, p { + font-family: verdana,arial,helvetica; + font-size: 80%; + color:#000000; + } + .dateAndAuthor { + font-family: verdana,arial,helvetica; + font-size: 80%; + font-weight: bold; + text-align:left; + background:#a6caf0; + } + tr, td{ + font-family: verdana,arial,helvetica; + font-size: 80%; + background:#eeeee0; + } + </style> + <h1> + <a name="top"><xsl:value-of select="$title"/></a> + </h1> + diff between <xsl:value-of select="@start"/><xsl:value-of select="@tag1"/> and <xsl:value-of select="@end"/><xsl:value-of select="@tag2"/> + <p align="right">Designed for use with <a href="http://ant.apache.org/">Apache Ant</a>.</p> + <hr size="2"/> + <a name="TOP"/> + <table width="100%"> + <tr> + <td align="right"> + <a href="#New">New Files</a> | + <a href="#Modified">Modified Files</a> | + <a href="#Removed">Removed Files</a> + </td> + </tr> + </table> + <TABLE BORDER="0" WIDTH="100%" CELLPADDING="3" CELLSPACING="1"> + <xsl:call-template name="show-paths"> + <xsl:with-param name="title">New Files</xsl:with-param> + <xsl:with-param name="anchor">New</xsl:with-param> + <xsl:with-param name="paths" select=".//path[action='added']"/> + </xsl:call-template> + + <xsl:call-template name="show-paths"> + <xsl:with-param name="title">Modified Files</xsl:with-param> + <xsl:with-param name="anchor">Modified</xsl:with-param> + <xsl:with-param name="paths" select=".//path[action='modified']"/> + </xsl:call-template> + + <xsl:call-template name="show-paths"> + <xsl:with-param name="title">Removed Files</xsl:with-param> + <xsl:with-param name="anchor">Removed</xsl:with-param> + <xsl:with-param name="paths" select=".//path[action='deleted']"/> + </xsl:call-template> + </TABLE> + + </BODY> + </HTML> + </xsl:template> + + <xsl:template name="show-paths"> + <xsl:param name="title"/> + <xsl:param name="anchor"/> + <xsl:param name="paths"/> + <TR> + <TD colspan="2" class="dateAndAuthor"> + <a> + <xsl:attribute name="name"><xsl:value-of select="$anchor"/></xsl:attribute> + <xsl:value-of select="$title"/> - <xsl:value-of select="count($paths)"/> entries + </a> + <a href="#TOP">(back to top)</a> + </TD> + </TR> + <TR> + <TD width="20"> + <xsl:text> </xsl:text> + </TD> + <TD> + <ul> + <xsl:apply-templates select="$paths"/> + </ul> + </TD> + </TR> + </xsl:template> + + <xsl:template match="path"> + <li> + <a target="_new"> + <xsl:attribute name="href"><xsl:value-of select="$repo"/>/<xsl:value-of select="name" /></xsl:attribute> + <xsl:value-of select="name" /> + </a> + </li> + </xsl:template> + + <!-- Any elements within a msg are processed, + so that we can preserve HTML tags. --> + <xsl:template match="msg"> + <b><xsl:apply-templates/></b> + </xsl:template> + +</xsl:stylesheet> Propchange: ant/sandbox/antlibs/svn/trunk/src/etc/diff.xsl ------------------------------------------------------------------------------ svn:eol-style = native Added: ant/sandbox/antlibs/svn/trunk/src/etc/testcases/abstractsvntask.xml URL: http://svn.apache.org/viewcvs/ant/sandbox/antlibs/svn/trunk/src/etc/testcases/abstractsvntask.xml?view=auto&rev=161469 ============================================================================== --- ant/sandbox/antlibs/svn/trunk/src/etc/testcases/abstractsvntask.xml (added) +++ ant/sandbox/antlibs/svn/trunk/src/etc/testcases/abstractsvntask.xml Fri Apr 15 07:32:50 2005 @@ -0,0 +1,64 @@ +<?xml version="1.0"?> + +<!-- + Copyright 2005 The Apache Software Foundation + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> + +<project name="abstractsvntask-test" basedir="../../../" + default="all" xmlns:svn="antlib:org.apache.tools.ant.taskdefs.svn"> + + <property name="tmpdir" value="tmpdir"/> + <property name="tpfdir" value="${tmpdir}/tpf"/> + <property name="file" value="ebcdic.h"/> + + <target name="setup"> + <mkdir dir="${tmpdir}"/> + <svn:svn + svnURL="http://svn.apache.org/repos/asf/httpd/httpd/trunk/os/tpf/" + dest="${tmpdir}"/> + </target> + + <target name="all" depends="setup"> + <svn:svn failonerror="true" subcommand="status ${file}" dest="${tpfdir}"/> + <svn:svn failonerror="true" dest="${tpfdir}"> + <commandline> + <argument value="up"/> + <argument value="-r"/> + <argument value="83750"/> + <argument value="${file}"/> + </commandline> + </svn:svn> + <svn:svn failonerror="true" subcommand="status ${file}" dest="${tpfdir}"/> + <svn:svn failonerror="true" dest="${tpfdir}"> + <commandline> + <argument line="up -r HEAD ${file}" /> + </commandline> + </svn:svn> + <svn:svn failonerror="true" subcommand="status ${file}" dest="${tpfdir}"/> + </target> + + <target name="revision-attribute"> + <mkdir dir="${tmpdir}" /> + <svn:svn + svnURL="http://svn.apache.org/repos/asf/httpd/httpd/trunk/os/tpf" + dest="${tmpdir}" + quiet="false" + revision="83750"/> + </target> + + <target name="cleanup"> + <delete dir="${tmpdir}" /> + </target> +</project> Propchange: ant/sandbox/antlibs/svn/trunk/src/etc/testcases/abstractsvntask.xml ------------------------------------------------------------------------------ svn:eol-style = native Added: ant/sandbox/antlibs/svn/trunk/src/etc/testcases/changelog.xml URL: http://svn.apache.org/viewcvs/ant/sandbox/antlibs/svn/trunk/src/etc/testcases/changelog.xml?view=auto&rev=161469 ============================================================================== --- ant/sandbox/antlibs/svn/trunk/src/etc/testcases/changelog.xml (added) +++ ant/sandbox/antlibs/svn/trunk/src/etc/testcases/changelog.xml Fri Apr 15 07:32:50 2005 @@ -0,0 +1,69 @@ +<?xml version="1.0"?> + +<!-- + Copyright 2005 The Apache Software Foundation + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> + +<project name="changelog-test" basedir="../../../" + default="log" xmlns:svn="antlib:org.apache.tools.ant.taskdefs.svn"> + + <property name="tmpdir" value="tmpdir"/> + <property name="trunkdir" value="${tmpdir}/trunk"/> + + <target name="setup"> + <mkdir dir="${tmpdir}"/> + <svn:svn + svnURL="http://svn.apache.org/repos/asf/jakarta/bcel/trunk" + dest="${tmpdir}"/> + </target> + + <target name="log" depends="setup"> + <svn:changelog failonerror="true" dest="${trunkdir}" + destfile="${tmpdir}/log.xml" /> + </target> + + <target name="start" depends="setup"> + <svn:changelog failonerror="true" dest="${trunkdir}" + destfile="${tmpdir}/log.xml" start="153000"/> + </target> + + <target name="startDate" depends="setup"> + <svn:changelog failonerror="true" dest="${trunkdir}" + destfile="${tmpdir}/log.xml" start="{2005-02-10}"/> + </target> + + <target name="end" depends="setup"> + <svn:changelog failonerror="true" dest="${trunkdir}" + destfile="${tmpdir}/log.xml" end="153000"/> + </target> + + <target name="endDate" depends="setup"> + <svn:changelog failonerror="true" dest="${trunkdir}" + destfile="${tmpdir}/log.xml" end="{2005-02-10}"/> + </target> + + <target name="report" depends="start"> + <style in="${tmpdir}/log.xml" + out="${tmpdir}/log.html" + style="src/etc/changelog.xsl"> + <param name="title" expression="Jakarta BCEL ChangeLog"/> + <param name="repo" expression="http://svn.apache.org/repos/asf"/> + </style> + </target> + + <target name="cleanup"> + <delete dir="${tmpdir}" /> + </target> +</project> Propchange: ant/sandbox/antlibs/svn/trunk/src/etc/testcases/changelog.xml ------------------------------------------------------------------------------ svn:eol-style = native Added: ant/sandbox/antlibs/svn/trunk/src/etc/testcases/revisiondiff.xml URL: http://svn.apache.org/viewcvs/ant/sandbox/antlibs/svn/trunk/src/etc/testcases/revisiondiff.xml?view=auto&rev=161469 ============================================================================== --- ant/sandbox/antlibs/svn/trunk/src/etc/testcases/revisiondiff.xml (added) +++ ant/sandbox/antlibs/svn/trunk/src/etc/testcases/revisiondiff.xml Fri Apr 15 07:32:50 2005 @@ -0,0 +1,58 @@ +<?xml version="1.0"?> + +<!-- + Copyright 2005 The Apache Software Foundation + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> + +<project name="revisiondiff-test" basedir="../../../" + default="diff" xmlns:svn="antlib:org.apache.tools.ant.taskdefs.svn"> + + <property name="tmpdir" value="tmpdir"/> + <property name="trunkdir" value="${tmpdir}/trunk"/> + + <target name="dir-prep"> + <mkdir dir="${tmpdir}"/> + </target> + + <target name="setup" depends="dir-prep"> + <svn:svn + svnURL="http://svn.apache.org/repos/asf/jakarta/bcel/trunk" + dest="${tmpdir}"/> + </target> + + <target name="diff" depends="setup"> + <svn:revisiondiff failonerror="true" dest="${trunkdir}" + destfile="${tmpdir}/diff.xml" start="152904" end="153682"/> + </target> + + <target name="diff-using-url" depends="dir-prep"> + <svn:revisiondiff failonerror="true" + svnURL="http://svn.apache.org/repos/asf/jakarta/bcel/trunk" + destfile="${tmpdir}/diff.xml" start="152904" end="153682"/> + </target> + + <target name="report" depends="diff-using-url"> + <style in="${tmpdir}/diff.xml" + out="${tmpdir}/diff.html" + style="src/etc/diff.xsl"> + <param name="title" expression="Jakarta BCEL diff"/> + <param name="repo" expression="http://svn.apache.org/repos/asf/jakarta/bcel/trunk"/> + </style> + </target> + + <target name="cleanup"> + <delete dir="${tmpdir}" /> + </target> +</project> Propchange: ant/sandbox/antlibs/svn/trunk/src/etc/testcases/revisiondiff.xml ------------------------------------------------------------------------------ svn:eol-style = native Added: ant/sandbox/antlibs/svn/trunk/src/etc/testcases/tagdiff.xml URL: http://svn.apache.org/viewcvs/ant/sandbox/antlibs/svn/trunk/src/etc/testcases/tagdiff.xml?view=auto&rev=161469 ============================================================================== --- ant/sandbox/antlibs/svn/trunk/src/etc/testcases/tagdiff.xml (added) +++ ant/sandbox/antlibs/svn/trunk/src/etc/testcases/tagdiff.xml Fri Apr 15 07:32:50 2005 @@ -0,0 +1,63 @@ +<?xml version="1.0"?> + +<!-- + Copyright 2005 The Apache Software Foundation + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> + +<project name="revisiondiff-test" basedir="../../../" + default="diff-with-implicit-trunk" + xmlns:svn="antlib:org.apache.tools.ant.taskdefs.svn"> + + <property name="tmpdir" value="tmpdir"/> + + <target name="dir-prep"> + <mkdir dir="${tmpdir}"/> + </target> + + <target name="diff-with-two-tags" depends="dir-prep"> + <svn:tagdiff failonerror="true" + baseURL="http://svn.apache.org/repos/asf/jakarta/bcel/" + destfile="${tmpdir}/diff.xml" + tag2="BCEL_5_0" tag1="initial"/> + </target> + + <target name="diff-with-explicit-trunk" depends="dir-prep"> + <svn:tagdiff failonerror="true" + baseURL="http://svn.apache.org/repos/asf/jakarta/bcel/" + destfile="${tmpdir}/diff.xml" + tag1="BCEL_5_0" tag2="trunk"/> + </target> + + <target name="diff-with-implicit-trunk" depends="dir-prep"> + <svn:tagdiff failonerror="true" + baseURL="http://svn.apache.org/repos/asf/jakarta/bcel/" + destfile="${tmpdir}/diff.xml" + tag1="BCEL_5_0"/> + </target> + + <!--target name="report" depends="diff-with-implicit-trunk"--> + <target name="report"> + <style in="/tmp/diff.xml" + out="/tmp/diff.html" + style="src/etc/diff.xsl"> + <param name="title" expression="Jakarta BCEL diff"/> + <param name="repo" expression="http://svn.apache.org/repos/asf/jakarta/bcel/trunk"/> + </style> + </target> + + <target name="cleanup"> + <delete dir="${tmpdir}" /> + </target> +</project> Propchange: ant/sandbox/antlibs/svn/trunk/src/etc/testcases/tagdiff.xml ------------------------------------------------------------------------------ svn:eol-style = native Added: ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/AbstractSvnTask.java URL: http://svn.apache.org/viewcvs/ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/AbstractSvnTask.java?view=auto&rev=161469 ============================================================================== --- ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/AbstractSvnTask.java (added) +++ ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/AbstractSvnTask.java Fri Apr 15 07:32:50 2005 @@ -0,0 +1,699 @@ +/* + * Copyright 2005 The Apache Software Foundation + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ + +package org.apache.tools.ant.taskdefs.svn; + +import java.io.BufferedOutputStream; +import java.io.File; +import java.io.FileOutputStream; +import java.io.IOException; +import java.io.OutputStream; +import java.io.PrintStream; +import java.util.Vector; +import org.apache.tools.ant.BuildException; +import org.apache.tools.ant.Project; +import org.apache.tools.ant.Task; +import org.apache.tools.ant.taskdefs.Execute; +import org.apache.tools.ant.taskdefs.ExecuteStreamHandler; +import org.apache.tools.ant.taskdefs.LogOutputStream; +import org.apache.tools.ant.taskdefs.PumpStreamHandler; +import org.apache.tools.ant.types.Commandline; +import org.apache.tools.ant.types.Environment; +import org.apache.tools.ant.util.StringUtils; + +/** + * Just like Ant's built-in CVS task, the main loginc lives in this + * abstract task. + */ +public abstract class AbstractSvnTask extends Task { + + private Commandline cmd = new Commandline(); + + /** list of Commandline children */ + private Vector vecCommandlines = new Vector(); + + /** + * the URL the subcommand should apply to. + */ + private String svnURL; + + /** + * the revision + */ + private String revision; + /** + * the default command. + */ + private static final String DEFAULT_SUBCOMMAND = "checkout"; + /** + * the SVN command to execute. + */ + private String subCommand = null; + + /** + * suppress information messages. + */ + private boolean quiet = false; + + /** + * be verbose + */ + private boolean verbose = false; + + /** + * report only, don't change any files. + */ + private boolean dryrun = false; + + /** + * the directory where the checked out files should be placed. + */ + private File dest; + + /** whether or not to append stdout/stderr to existing files */ + private boolean append = false; + + /** + * the file to direct standard output from the command. + */ + private File output; + + /** + * the file to direct standard error from the command. + */ + private File error; + + /** + * If true it will stop the build if svn exits with error. + * Default is false. (Iulian) + */ + private boolean failOnError = false; + + /** + * Uses the contents of the file passed as an argument to this + * switch for the specified subcommand. + */ + private File file; + + /** + * Forces a particular command or operation to run. + */ + private boolean force; + + /** + * Makes a subcommand recurse into subdirectories. + */ + private Boolean recursive = null; + + /** + * Tells Subversion to get the list of files that you wish to + * operate on from the filename you provide instead of listing all + * the files on the command line. + */ + private File targets; + + /** + * Create accessors for the following, to allow different handling of + * the output. + */ + private ExecuteStreamHandler executeStreamHandler; + private OutputStream outputStream; + private OutputStream errorStream; + + /** empty no-arg constructor*/ + public AbstractSvnTask() { + super(); + } + + /** + * sets the handler + * @param handler a handler able of processing the output and error streams from the svn exe + */ + public void setExecuteStreamHandler(ExecuteStreamHandler handler) { + this.executeStreamHandler = handler; + } + + /** + * find the handler and instantiate it if it does not exist yet + * @return handler for output and error streams + */ + protected ExecuteStreamHandler getExecuteStreamHandler() { + + if (this.executeStreamHandler == null) { + setExecuteStreamHandler(new PumpStreamHandler(getOutputStream(), + getErrorStream())); + } + + return this.executeStreamHandler; + } + + /** + * sets a stream to which the output from the svn executable should be sent + * @param outputStream stream to which the stdout from svn should go + */ + protected void setOutputStream(OutputStream outputStream) { + + this.outputStream = outputStream; + } + + /** + * access the stream to which the stdout from svn should go + * if this stream has already been set, it will be returned + * if the stream has not yet been set, if the attribute output + * has been set, the output stream will go to the output file + * otherwise the output will go to ant's logging system + * @return output stream to which svn' stdout should go to + */ + protected OutputStream getOutputStream() { + + if (this.outputStream == null) { + + if (output != null) { + try { + setOutputStream(new PrintStream( + new BufferedOutputStream( + new FileOutputStream(output + .getPath(), + append)))); + } catch (IOException e) { + throw new BuildException(e, getLocation()); + } + } else { + setOutputStream(new LogOutputStream(this, Project.MSG_INFO)); + } + } + + return this.outputStream; + } + + /** + * sets a stream to which the stderr from the svn exe should go + * @param errorStream an output stream willing to process stderr + */ + protected void setErrorStream(OutputStream errorStream) { + + this.errorStream = errorStream; + } + + /** + * access the stream to which the stderr from svn should go + * if this stream has already been set, it will be returned + * if the stream has not yet been set, if the attribute error + * has been set, the output stream will go to the file denoted by the error attribute + * otherwise the stderr output will go to ant's logging system + * @return output stream to which svn' stderr should go to + */ + protected OutputStream getErrorStream() { + + if (this.errorStream == null) { + + if (error != null) { + + try { + setErrorStream(new PrintStream( + new BufferedOutputStream( + new FileOutputStream(error.getPath(), + append)))); + } catch (IOException e) { + throw new BuildException(e, getLocation()); + } + } else { + setErrorStream(new LogOutputStream(this, Project.MSG_WARN)); + } + } + + return this.errorStream; + } + + /** + * Sets up the environment for toExecute and then runs it. + * @param toExecute the command line to execute + * @throws BuildException if failonError is set to true and the svn command fails + */ + protected void runCommand(Commandline toExecute) throws BuildException { + Environment env = new Environment(); + + // + // Just call the getExecuteStreamHandler() and let it handle + // the semantics of instantiation or retrieval. + // + Execute exe = new Execute(getExecuteStreamHandler(), null); + + exe.setAntRun(getProject()); + if (dest == null) { + dest = getProject().getBaseDir(); + } + + if (!dest.exists()) { + dest.mkdirs(); + } + + exe.setWorkingDirectory(dest); + exe.setCommandline(toExecute.getCommandline()); + exe.setEnvironment(env.getVariables()); + + try { + String actualCommandLine = executeToString(exe); + log(actualCommandLine, Project.MSG_VERBOSE); + int retCode = exe.execute(); + log("retCode=" + retCode, Project.MSG_DEBUG); + /*Throw an exception if svn exited with error. (Iulian)*/ + if (failOnError && Execute.isFailure(retCode)) { + throw new BuildException("svn exited with error code " + + retCode + + StringUtils.LINE_SEP + + "Command line was [" + + actualCommandLine + "]", getLocation()); + } + } catch (IOException e) { + if (failOnError) { + throw new BuildException(e, getLocation()); + } else { + log("Caught exception: " + e.getMessage(), Project.MSG_WARN); + } + } catch (BuildException e) { + if (failOnError) { + throw(e); + } else { + Throwable t = e.getException(); + if (t == null) { + t = e; + } + log("Caught exception: " + t.getMessage(), Project.MSG_WARN); + } + } catch (Exception e) { + if (failOnError) { + throw new BuildException(e, getLocation()); + } else { + log("Caught exception: " + e.getMessage(), Project.MSG_WARN); + } + } + } + + /** + * do the work + * @throws BuildException if failonerror is set to true and the svn command fails. + */ + public void execute() throws BuildException { + + String savedCommand = getSubCommand(); + + if (this.getSubCommand() == null && vecCommandlines.size() == 0) { + // re-implement legacy behaviour: + this.setSubCommand(AbstractSvnTask.DEFAULT_SUBCOMMAND); + } + + String c = this.getSubCommand(); + Commandline cloned = null; + if (c != null) { + cloned = (Commandline) cmd.clone(); + cloned.createArgument(true).setLine(c); + if (svnURL != null) { + cloned.createArgument().setValue(svnURL); + } + this.addConfiguredCommandline(cloned, true); + } + + try { + for (int i = 0; i < vecCommandlines.size(); i++) { + this.runCommand((Commandline) vecCommandlines.elementAt(i)); + } + } finally { + if (cloned != null) { + removeCommandline(cloned); + } + setSubCommand(savedCommand); + + if (outputStream != null) { + try { + outputStream.close(); + } catch (IOException e) { + //ignore + } + } + if (errorStream != null) { + try { + errorStream.close(); + } catch (IOException e) { + //ignore + } + } + } + } + + private String executeToString(Execute execute) { + + StringBuffer stringBuffer = + new StringBuffer(Commandline.describeCommand(execute + .getCommandline())); + + String newLine = StringUtils.LINE_SEP; + String[] variableArray = execute.getEnvironment(); + + if (variableArray != null) { + stringBuffer.append(newLine); + stringBuffer.append(newLine); + stringBuffer.append("environment:"); + stringBuffer.append(newLine); + for (int z = 0; z < variableArray.length; z++) { + stringBuffer.append(newLine); + stringBuffer.append("\t"); + stringBuffer.append(variableArray[z]); + } + } + + return stringBuffer.toString(); + } + + /** + * The URL the subcommand should apply to. + * + * @param url the URL the subcommand should apply to. + */ + public void setSvnURL(String url) { + + // Check if not real svnroot => set it to null + if (url != null) { + if (url.trim().equals("")) { + url = null; + } + } + + this.svnURL = url; + } + + /** + * access the svnURL variable + * @return svnURL + */ + public String getSvnURL() { + + return this.svnURL; + } + + /** + * The directory where the checked out files should be placed. + * + * <p>Note that this is different from SVN's -d command line + * switch as Ant will never shorten pathnames to avoid empty + * directories.</p> + * + * @param dest directory where the checked out files should be placed + */ + public void setDest(File dest) { + this.dest = dest; + } + + /** + * get the file where the checked out files should be placed + * + * @return directory where the checked out files should be placed + */ + public File getDest() { + + return this.dest; + } + + /** + * revision + * @return revision + */ + public String getRevision() { + return revision; + } + + /** + * The revision to operate upon. + * @param p revision + */ + public void setRevision(String p) { + // Check if not real revision => set it to null + if (p != null && p.trim().length() > 0) { + revision = p; + addSubCommandArgument("--revision"); + addSubCommandArgument(p); + } + } + + /** + * Uses the contents of the file passed as an argument to this + * switch for the specified subcommand. + */ + public void setFile(File file) { + this.file = file; + } + + /** + * Uses the contents of the file passed as an argument to this + * switch for the specified subcommand. + */ + public File getFile() { + return file; + } + + /** + * Forces a particular command or operation to run. + */ + public void setForce(boolean force) { + this.force = force; + } + + /** + * Forces a particular command or operation to run. + */ + public boolean getForce() { + return force; + } + + /** + * Makes a subcommand recurse into subdirectories. Most + * subcommands recurse by default. + */ + public void setRecursive(Boolean recursive) { + this.recursive = recursive; + } + + /** + * Makes a subcommand recurse into subdirectories. Most + * subcommands recurse by default. + */ + public Boolean getRecursive() { + return recursive; + } + + /** + * Tells Subversion to get the list of files that you wish to + * operate on from the filename you provide instead of listing all + * the files on the command line. + */ + public void setTargets(File targets) { + this.targets = targets; + } + + /** + * Tells Subversion to get the list of files that you wish to + * operate on from the filename you provide instead of listing all + * the files on the command line. + */ + public File getTargets() { + return targets; + } + + /** + * This needs to be public to allow configuration + * of commands externally. + * @param arg command argument + */ + public void addSubCommandArgument(String arg) { + this.addSubCommandArgument(cmd, arg); + } + + /** + * This method adds a command line argument to an external subcommand. + * + * @param c command line to which one argument should be added + * @param arg argument to add + */ + protected void addSubCommandArgument(Commandline c, String arg) { + c.createArgument().setValue(arg); + } + + + /** + * The SVN command to execute. + * + * @param c a command as string + */ + public void setSubCommand(String c) { + this.subCommand = c; + } + /** + * accessor to a command line as string + * + * @return command line as string + */ + public String getSubCommand() { + return this.subCommand; + } + + /** + * If true, suppress informational messages. + * @param q if true, suppress informational messages + */ + public void setQuiet(boolean q) { + quiet = q; + } + + /** + * If true, be verbose. + * @param q if true, be verbose. + */ + public void setVerbose(boolean v) { + verbose = v; + } + + /** + * If true, report only and don't change any files. + * + * @param ne if true, report only and do not change any files. + */ + public void setDryrun(boolean ne) { + dryrun = ne; + } + + /** + * The file to direct standard output from the command. + * @param output a file to which stdout should go + */ + public void setOutput(File output) { + this.output = output; + } + + /** + * The file to direct standard error from the command. + * + * @param error a file to which stderr should go + */ + public void setError(File error) { + this.error = error; + } + + /** + * Whether to append output/error when redirecting to a file. + * @param value true indicated you want to append + */ + public void setAppend(boolean value) { + this.append = value; + } + + /** + * Stop the build process if the command exits with + * a return code other than 0. + * Defaults to false. + * @param failOnError stop the build process if the command exits with + * a return code other than 0 + */ + public void setFailOnError(boolean failOnError) { + this.failOnError = failOnError; + } + + /** + * Configure a commandline element for things like quiet, etc. + * @param c the command line which will be configured + * if the commandline is initially null, the function is a noop + * otherwise the function append to the commandline arguments concerning + * <ul> + * <li> + * svn + * </li> + * <li> + * quiet + * </li> + * <li>verbose</li> + * <li>dryrun</li> + * </ul> + */ + protected void configureCommandline(Commandline c) { + if (c == null) { + return; + } + c.setExecutable("svn"); + if (quiet) { + c.createArgument(true).setValue("--quiet"); + } + if (verbose) { + c.createArgument(true).setValue("--verbose"); + } + if (dryrun) { + c.createArgument(true).setValue("--dry-run"); + } + if (file != null) { + c.createArgument(true).setValue("--file"); + c.createArgument(true).setFile(file); + } + if (force) { + c.createArgument(true).setValue("--force"); + } + if (recursive != null) { + if (recursive.booleanValue()) { + c.createArgument(true).setValue("--recursive"); + } else { + c.createArgument(true).setValue("--non-recursive"); + } + } + if (targets != null) { + c.createArgument(true).setValue("--targets"); + c.createArgument(true).setFile(targets); + } + } + + /** + * remove a particular command from a vector of command lines + * @param c command line which should be removed + */ + protected void removeCommandline(Commandline c) { + vecCommandlines.removeElement(c); + } + + /** + * Adds direct command-line to execute. + * @param c command line to execute + */ + public void addConfiguredCommandline(Commandline c) { + this.addConfiguredCommandline(c, false); + } + + /** + * Configures and adds the given Commandline. + * @param c commandline to insert + * @param insertAtStart If true, c is + * inserted at the beginning of the vector of command lines + */ + public void addConfiguredCommandline(Commandline c, + boolean insertAtStart) { + if (c == null) { + return; + } + this.configureCommandline(c); + if (insertAtStart) { + vecCommandlines.insertElementAt(c, 0); + } else { + vecCommandlines.addElement(c); + } + } + +} Propchange: ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/AbstractSvnTask.java ------------------------------------------------------------------------------ svn:eol-style = native Added: ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/LineOrientedOutputStream.java URL: http://svn.apache.org/viewcvs/ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/LineOrientedOutputStream.java?view=auto&rev=161469 ============================================================================== --- ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/LineOrientedOutputStream.java (added) +++ ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/LineOrientedOutputStream.java Fri Apr 15 07:32:50 2005 @@ -0,0 +1,134 @@ +/* + * Copyright 2005 The Apache Software Foundation + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ + +package org.apache.tools.ant.taskdefs.svn; + +import java.io.ByteArrayOutputStream; +import java.io.IOException; +import java.io.OutputStream; + +/** + * Invokes [EMAIL PROTECTED] #processLine processLine} whenever a full line has + * been written to this stream. + * + * <p>Tries to be smart about line separators.</p> + */ +public abstract class LineOrientedOutputStream extends OutputStream { + + /** Initial buffer size. */ + private static final int INTIAL_SIZE = 132; + + /** Carriage return */ + private static final int CR = 0x0d; + + /** Linefeed */ + private static final int LF = 0x0a; + + private ByteArrayOutputStream buffer + = new ByteArrayOutputStream(INTIAL_SIZE); + private boolean skip = false; + + /** + * Write the data to the buffer and flush the buffer, if a line + * separator is detected. + * + * @param cc data to log (byte). + */ + public final void write(int cc) throws IOException { + final byte c = (byte) cc; + if ((c == '\n') || (c == '\r')) { + if (!skip) { + processBuffer(); + } + } else { + buffer.write(cc); + } + skip = (c == '\r'); + } + + /** + * Flush this log stream + */ + public final void flush() throws IOException { + if (buffer.size() > 0) { + processBuffer(); + } + } + + /** + * Converts the buffer to a string and sends it to + * <code>processLine</code> + */ + private void processBuffer() throws IOException { + try { + processLine(buffer.toString()); + } finally { + buffer.reset(); + } + } + + /** + * Processes a line. + * + * @param line the line to log. + */ + protected abstract void processLine(String line) throws IOException; + + /** + * Writes all remaining + */ + public final void close() throws IOException { + if (buffer.size() > 0) { + processBuffer(); + } + super.close(); + } + + /** + * Write a block of characters to the output stream + * + * @param b the array containing the data + * @param off the offset into the array where data starts + * @param len the length of block + * + * @throws IOException if the data cannot be written into the stream. + */ + public final void write(byte[] b, int off, int len) throws IOException { + // find the line breaks and pass other chars through in blocks + int offset = off; + int blockStartOffset = offset; + int remaining = len; + while (remaining > 0) { + while (remaining > 0 && b[offset] != LF && b[offset] != CR) { + offset++; + remaining--; + } + // either end of buffer or a line separator char + int blockLength = offset - blockStartOffset; + if (blockLength > 0) { + buffer.write(b, blockStartOffset, blockLength); + } + while (remaining > 0 && (b[offset] == LF || b[offset] == CR)) { + write(b[offset]); + offset++; + remaining--; + } + blockStartOffset = offset; + } + } + +} Propchange: ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/LineOrientedOutputStream.java ------------------------------------------------------------------------------ svn:eol-style = native Added: ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/Svn.java URL: http://svn.apache.org/viewcvs/ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/Svn.java?view=auto&rev=161469 ============================================================================== --- ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/Svn.java (added) +++ ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/Svn.java Fri Apr 15 07:32:50 2005 @@ -0,0 +1,32 @@ +/* + * Copyright 2005 The Apache Software Foundation + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ + +package org.apache.tools.ant.taskdefs.svn; + +/** + * Performs operations on a SVN repository. + * + * @ant.task category="scm" + */ +public class Svn extends AbstractSvnTask { + + /** + * SVN Task - now implemented by the Abstract SVN Task base class + */ + public Svn() { + } +} Propchange: ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/Svn.java ------------------------------------------------------------------------------ svn:eol-style = native Added: ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/SvnChangeLogParser.java URL: http://svn.apache.org/viewcvs/ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/SvnChangeLogParser.java?view=auto&rev=161469 ============================================================================== --- ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/SvnChangeLogParser.java (added) +++ ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/SvnChangeLogParser.java Fri Apr 15 07:32:50 2005 @@ -0,0 +1,188 @@ +/* + * Copyright 2005 The Apache Software Foundation + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + */ +package org.apache.tools.ant.taskdefs.svn; + +import java.text.ParseException; +import java.text.SimpleDateFormat; +import java.util.Date; +import java.util.ArrayList; + +/** + * A class used to parse the output of the svn log command. + * + */ +class SvnChangeLogParser extends LineOrientedOutputStream { + + private final static int GET_ENTRY_LINE = 0; + private final static int GET_REVISION_LINE = 1; + private final static int GET_PATHS = 2; + private final static int GET_MESSAGE = 3; + + private String message = ""; + private Date date = null; + private String author = null; + private String revision = null; + private ArrayList paths = new ArrayList(); + + /** input format for dates read in from cvs log */ + private static final String PATTERN = "yyyy-MM-dd HH:mm:ss"; + private static final SimpleDateFormat INPUT_DATE + = new SimpleDateFormat(PATTERN); + + private final ArrayList entries = new ArrayList(); + private int status = GET_ENTRY_LINE; + + /** + * Get a list of rcs entries as an array. + * + * @return a list of rcs entries as an array + */ + public SvnEntry[] getEntrySetAsArray() { + return (SvnEntry[]) entries.toArray(new SvnEntry[entries.size()]); + } + + /** + * Receive notification about the process writing + * to standard output. + * @param line the line to process + */ + public void processLine(final String line) { + switch(status) { + case GET_ENTRY_LINE: + // make sure attributes are reset when + // working on a 'new' file. + reset(); + processEntryStart(line); + break; + case GET_REVISION_LINE: + processRevision(line); + break; + + case GET_MESSAGE: + processMessage(line); + break; + + case GET_PATHS: + processPath(line); + break; + + default: + // Do nothing + break; + } + } + + /** + * Process a line while in "GET_MESSAGE" state. + * + * @param line the line + */ + private void processMessage(final String line) { + final String lineSeparator = System.getProperty("line.separator"); + if (line.equals("------------------------------------------------------------------------")) { + //We have ended changelog for that particular revision + //so we can save it + final int end + = message.length() - lineSeparator.length(); + message = message.substring(0, end); + saveEntry(); + status = GET_REVISION_LINE; + } else { + message += line + lineSeparator; + } + } + + /** + * Process a line while in "GET_ENTRY_LINE" state. + * + * @param line the line to process + */ + private void processEntryStart(final String line) { + if (line.equals("------------------------------------------------------------------------")) { + status = GET_REVISION_LINE; + } + } + + /** + * Process a line while in "REVISION" state. + * + * @param line the line to process + */ + private void processRevision(final String line) { + int index = line.indexOf(" |"); + if (line.startsWith("r") + && (line.endsWith("lines") || line.endsWith("line")) + && index > -1) { + revision = line.substring(1, index); + int end = line.indexOf(" |", index + 1); + author = line.substring(index + 3, end); + String d = line.substring(end + 3, end + 3 + PATTERN.length()); + date = parseDate(d); + status = GET_PATHS; + } + } + + /** + * Process a line while in "GET_PATHS" state. + * + * @param line the line to process + */ + private void processPath(final String line) { + if (line.startsWith("Changed paths:")) { + // ignore + } else if (line.equals("")) { + status = GET_MESSAGE; + } else if (line.length() > 5) { + paths.add(new SvnEntry.Path(line.substring(5), line.charAt(3))); + } + } + + /** + * Utility method that saves the current entry. + */ + private void saveEntry() { + SvnEntry entry = new SvnEntry(date, revision, author, message, + paths); + entries.add(entry); + reset(); + } + + /** + * Parse date out from expected format. + * + * @param date the string holding date + * @return the date object or null if unknown date format + */ + private Date parseDate(final String date) { + try { + return INPUT_DATE.parse(date); + } catch (ParseException e) { + return null; + } + } + + /** + * Reset all internal attributes except status. + */ + public void reset() { + this.date = null; + this.author = null; + this.message = ""; + this.revision = null; + this.paths.clear(); + } +} Propchange: ant/sandbox/antlibs/svn/trunk/src/main/org/apache/tools/ant/taskdefs/svn/SvnChangeLogParser.java ------------------------------------------------------------------------------ svn:eol-style = native --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]