[jbosstools-commits] JBoss Tools SVN: r22382 - trunk/build.
jbosstools-commits at lists.jboss.org
jbosstools-commits at lists.jboss.org
Thu May 27 13:22:32 EDT 2010
Author: nickboldt
Date: 2010-05-27 13:22:32 -0400 (Thu, 27 May 2010)
New Revision: 22382
Modified:
trunk/build/publish.sh
Log:
wrap everything with an if-exists-then-do
Modified: trunk/build/publish.sh
===================================================================
--- trunk/build/publish.sh 2010-05-27 17:10:37 UTC (rev 22381)
+++ trunk/build/publish.sh 2010-05-27 17:22:32 UTC (rev 22382)
@@ -7,15 +7,24 @@
# define target zip filename for inclusion in uberbuilder's bucky aggregator
SNAPNAME=${JOB_NAME}-Update-SNAPSHOT.zip
-# copy into workspace for archiving
rm -fr ${WORKSPACE}/site; mkdir -p ${WORKSPACE}/site/${JOB_NAME}
-rsync -aq ${WORKSPACE}/*/site/target/site.zip ${WORKSPACE}/site/${JOB_NAME}/${ZIPNAME}
-rsync -aq ${WORKSPACE}/*/*/site/target/*Update*.zip ${WORKSPACE}/site/${JOB_NAME}/
+if [[ -f ${WORKSPACE}/*/site/target/site.zip ]]; then
+ # copy into workspace for archiving
+ rsync -aq ${WORKSPACE}/*/site/target/site.zip ${WORKSPACE}/site/${JOB_NAME}/${ZIPNAME}
+ # copy into workspace for access by bucky aggregator
+ rsync -aq ${WORKSPACE}/*/site/target/site.zip ${WORKSPACE}/site/${SNAPNAME}
+fi
-# copy into workspace for access by bucky aggregator
-rsync -aq ${WORKSPACE}/*/site/target/site.zip ${WORKSPACE}/site/${SNAPNAME}
+# if zips exist produced & renamed by ant script, copy them too
+if [[ -f ${WORKSPACE}/*/*/site/target/*Update*.zip ]]; then
+ rsync -aq ${WORKSPACE}/*/*/site/target/*Update*.zip ${WORKSPACE}/site/${JOB_NAME}/
+fi
# publish to download.jboss.org
if [[ $DESTINATION == "" ]]; then DESTINATION="tools at filemgmt.jboss.org:/downloads_htdocs/tools"; fi
-rsync -arzq --delete ${WORKSPACE}/site/${JOB_NAME} $DESTINATION/builds/nightly/3.2.helios/
-rsync -arzq --delete ${WORKSPACE}/site/${SNAPNAME} $DESTINATION/builds/nightly/3.2.helios/
+if [[ -d ${WORKSPACE}/site/${JOB_NAME} ]]; then
+ rsync -arzq --delete ${WORKSPACE}/site/${JOB_NAME} $DESTINATION/builds/nightly/3.2.helios/
+fi
+if [[ -d ${WORKSPACE}/site/${SNAPNAME} ]]; then
+ rsync -arzq --delete ${WORKSPACE}/site/${SNAPNAME} $DESTINATION/builds/nightly/3.2.helios/
+fi
\ No newline at end of file
More information about the jbosstools-commits
mailing list