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/26 16:28:42 UTC

svn commit: rev 30717 - forrest/trunk/src/forrestbot/core

Author: brondsem
Date: Mon Jul 26 07:28:41 2004
New Revision: 30717

Modified:
   forrest/trunk/src/forrestbot/core/build.xml
   forrest/trunk/src/forrestbot/core/deploy.xml
   forrest/trunk/src/forrestbot/core/forrestbot.xml
Log:
proper error handling on site build failure; add clean target; fixes FOR-81

Modified: forrest/trunk/src/forrestbot/core/build.xml
==============================================================================
--- forrest/trunk/src/forrestbot/core/build.xml	(original)
+++ forrest/trunk/src/forrestbot/core/build.xml	Mon Jul 26 07:28:41 2004
@@ -62,7 +62,6 @@
         <echo>Oops, something broke</echo>
         <property name="notify.completion-status" value="FAILED" />
         <property name="build.failed" value="true"/>
-        <throw refid="exception" message="${errmsg}"/>
       </catch>
     </trycatch>
     <copy file="${build.logfile}" tofile="${build.logfile-stored}"/>

Modified: forrest/trunk/src/forrestbot/core/deploy.xml
==============================================================================
--- forrest/trunk/src/forrestbot/core/deploy.xml	(original)
+++ forrest/trunk/src/forrestbot/core/deploy.xml	Mon Jul 26 07:28:41 2004
@@ -18,7 +18,7 @@
 
   <property name="deploy.local.dir" location="sites/${ant.project.name}"/>
 
-  <target name="deploy.local" description="FB: Deploy to a local location">
+  <target name="deploy.local" unless="build.failed" description="FB: Deploy to a local location">
     <mkdir dir="${deploy.local.dir}"/>
     <echo>Deploying from ${build.site-dir} to ${deploy.local.dir}</echo>
     <copy todir="${deploy.local.dir}">
@@ -30,7 +30,7 @@
   </target>
 
   <property name="deploy.scp.dest" value=""/>
-  <target name="deploy.scp" description="FB: Deploy to a remote location via scp">
+  <target name="deploy.scp" unless="build.failed" description="FB: Deploy to a remote location via scp">
     <if>
       <not><isset property="deploy.scp.password"/></not>
       <then>
@@ -51,7 +51,7 @@
   
   <property name="deploy.cvsmodule-dir" value="work/cvsmodules-deploy/${ant.project.name}"/>
   
-  <target name="deploy.cvs" description="FB: Deploy by committing to a CVS repository">
+  <target name="deploy.cvs" unless="build.failed" description="FB: Deploy by committing to a CVS repository">
     <condition property="isUnix">
         <os family="unix"/>
     </condition>
@@ -88,7 +88,7 @@
   
   <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">
+  <target name="deploy.svn" unless="build.failed" description="FB: Deploy by committing to an SVN repository">
     <!-- get current SVN source -->
     <svncheckout
         repositoryurl="${deploy.svn.url}"

Modified: forrest/trunk/src/forrestbot/core/forrestbot.xml
==============================================================================
--- forrest/trunk/src/forrestbot/core/forrestbot.xml	(original)
+++ forrest/trunk/src/forrestbot/core/forrestbot.xml	Mon Jul 26 07:28:41 2004
@@ -38,6 +38,14 @@
 
   <target name="notify" depends="notify.local" description="FB: Notify via notify.local"/>
 
+  <target name="clean">
+    <antcall target="forrest.clean" inheritAll="false">
+      <param name="project.home" value="${build.work-dir}"/>
+      <param name="project.build-dir" value="${build.work-dir}"/>
+      <param name="project.site-dir" value="${build.site-dir}"/>
+    </antcall>
+  </target>
+
   <!-- run the workstages -->
   <target name="main" depends="getsrc, build, deploy, notify" description="FB: getsrc, build, deploy, notify"/>