You are viewing a plain text version of this content. The canonical link for it is here.
Posted to svn@forrest.apache.org by br...@apache.org on 2004/07/19 06:14:17 UTC
svn commit: rev 23050 - in forrest/trunk: . src/documentation/content/xdocs/docs src/forrestbot src/forrestbot/core
Author: brondsem
Date: Sun Jul 18 21:14:15 2004
New Revision: 23050
Modified:
forrest/trunk/src/documentation/content/xdocs/docs/forrestbot.xml
forrest/trunk/src/forrestbot/core/deploy.xml
forrest/trunk/src/forrestbot/forrest.xml
forrest/trunk/status.xml
Log:
add forrestbot deploy.svn implmentation; fixes FOR-219
Modified: forrest/trunk/src/documentation/content/xdocs/docs/forrestbot.xml
==============================================================================
--- forrest/trunk/src/documentation/content/xdocs/docs/forrestbot.xml (original)
+++ forrest/trunk/src/documentation/content/xdocs/docs/forrestbot.xml Sun Jul 18 21:14:15 2004
@@ -115,6 +115,8 @@
<li><link href="#deploy.scp">deploy.scp</link></li>
<li><link href="#deploy.cvs">deploy.cvs</link></li>
+
+ <li><link href="#deploy.svn">deploy.svn</link></li>
</ul></td>
</tr>
@@ -300,7 +302,7 @@
<tr>
<td>getsrc.svn.url</td>
- <td>full repository URL for project (this directory must contain
+ <td>Full repository URL for project (this directory must contain
forrest.properties)</td>
<td></td>
@@ -424,7 +426,7 @@
</table>
</section>
- <section>
+ <section id="deploy.cvs">
<title>deploy.cvs</title>
<p>This is only available on *nix operating systems.</p>
@@ -492,6 +494,63 @@
<tr>
<td>deploy.cvs.commit-message</td>
+
+ <td>Message to use when committing. You probably want to put a
+ machine name or person's name here.</td>
+
+ <td>Automatic publish from forrestbot</td>
+
+ <td>No</td>
+ </tr>
+ </table>
+ </section>
+
+ <section id="deploy.svn">
+ <title>deploy.svn</title>
+
+ <table>
+ <tr>
+ <th>Property</th>
+
+ <th>Description</th>
+
+ <th>Default Value</th>
+
+ <th>Required?</th>
+ </tr>
+
+ <tr>
+ <td>deploy.svn.user</td>
+
+ <td>SVN username to use when committing changes</td>
+
+ <td></td>
+
+ <td>Yes</td>
+ </tr>
+
+ <tr>
+ <td>deploy.svn.password</td>
+
+ <td>SVN password</td>
+
+ <td></td>
+
+ <td>Yes</td>
+ </tr>
+
+ <tr>
+ <td>deploy.svn.url</td>
+
+ <td>Full repository URL</td>
+
+ <td></td>
+
+ <td>Yes</td>
+ </tr>
+
+ <tr>
+ <td>deploy.svn.commit-message</td>
<td>Message to use when committing. You probably want to put a
machine name or person's name here.</td>
Modified: forrest/trunk/src/forrestbot/core/deploy.xml
==============================================================================
--- forrest/trunk/src/forrestbot/core/deploy.xml (original)
+++ forrest/trunk/src/forrestbot/core/deploy.xml Sun Jul 18 21:14:15 2004
@@ -80,4 +80,57 @@
</exec>
</target>
+
+ <property name="deploy.svn.user" value=""/>
+ <property name="deploy.svn.password" value=""/>
+ <property name="deploy.svn.url" value=""/>
+ <property name="deploy.svn.commit-message" value="Automatic publish from forrestbot"/>
+
+ <property name="deploy.svn.svn-dir" location="work/svn-deploy/${ant.project.name}"/>
+ <property name="deploy.svn.svn-filestoadd" location="work/svn-deploy/${ant.project.name}.toadd"/>
+ <target name="deploy.svn" description="FB: Deploy by committing to an SVN repository">
+ <!-- get current SVN source -->
+ <svncheckout
+ repositoryurl="${deploy.svn.url}"
+ username="${deploy.svn.user}"
+ password="${deploy.svn.password}"
+ destination="${deploy.svn.svn-dir}"
+ failonerror="true"
+ />
+
+ <!-- copy new files into sandbox -->
+ <copy todir="${deploy.svn.svn-dir}">
+ <fileset dir="${build.site-dir}"/>
+ </copy>
+
+ <!-- add new files to CVS -->
+ <!-- svnadd doesn't work (it doesn't change the working directory properly) -->
+ <exec executable="svn" dir="${deploy.svn.svn-dir}" output="${deploy.svn.svn-filestoadd}" failonerror="true">
+ <arg value="status"/>
+ </exec>
+ <!-- the status columns make all lines invalid filenames
+ we remove the status columns for the new files so the only valid
+ filenames in the list are new files
+ -->
+ <replace file="${deploy.svn.svn-filestoadd}" token="? " value=""/>
+ <replace file="${deploy.svn.svn-filestoadd}" token="M " value=""/>
+ <!-- don't fail on error here because
+ 1) the targets file might have 'bad' filenames but we should continue
+ 2) we would've already failed if the svn executable wasn't found
+ -->
+ <exec executable="svn" dir="${deploy.svn.svn-dir}">
+ <arg value="add"/>
+ <arg value="--targets"/>
+ <arg value="${deploy.svn.svn-filestoadd}"/>
+ </exec>
+ <!-- check in to SVN
+ <svncommit
+ target="${deploy.svn.svn-dir}"
+ repositoryurl="${deploy.svn.url}"
+ commitmessage="${deploy.svn.commit-message}"
+ verbose="true"
+ />-->
+
+ </target>
+
</project>
Modified: forrest/trunk/src/forrestbot/forrest.xml
==============================================================================
--- forrest/trunk/src/forrestbot/forrest.xml (original)
+++ forrest/trunk/src/forrestbot/forrest.xml Sun Jul 18 21:14:15 2004
@@ -20,10 +20,10 @@
<target name="getsrc" depends="getsrc.svn"/>
<!-- create this file to be an ant project (not stored in CVS or SVN)
- that sets deploy.cvs.user and deploy.cvs.password propeties -->
- <import file="deploy.cvs.settings" optional="true"/>
- <property name="deploy.cvs.module" value="xml-site/targets/forrest"/>
- <target name="deploy" depends="deploy.cvs"/>
+ that sets deploy.svn.user and deploy.svn.password propeties -->
+ <import file="deploy.svn.settings" optional="true"/>
+ <property name="deploy.svn.url" value="https://svn.apache.org/repos/asf/forrest/site"/>
+ <target name="deploy" depends="deploy.svn"/>
<property environment="env"/>
<import file="${env.FORREST_HOME}/../forrestbot/core/forrestbot.xml"/>
Modified: forrest/trunk/status.xml
==============================================================================
--- forrest/trunk/status.xml (original)
+++ forrest/trunk/status.xml Sun Jul 18 21:14:15 2004
@@ -50,6 +50,9 @@
Added new document to facilitate
<link href="site:upgrading_06">upgrading to v0.6</link>
</action>
+ <action dev="DB" type="add" context="forrestbot" fixes-bug="FOR-219">
+ Added forrestbot deploy.svn implmentation.
+ </action>
<action dev="DB" type="update" context="build" fixes-bug="FOR-113" due-to="Pierrick Brihaye">
Support running Forrest on Win9x.
</action>