Author: nickboldt
Date: 2012-02-20 13:24:14 -0500 (Mon, 20 Feb 2012)
New Revision: 38916
Modified:
branches/jbosstools-3.3.0.Beta1/build/publish.sh
Log:
publishing step not correctly cycling internal mirror (JBDS-2028)
Modified: branches/jbosstools-3.3.0.Beta1/build/publish.sh
===================================================================
--- branches/jbosstools-3.3.0.Beta1/build/publish.sh 2012-02-20 18:23:17 UTC (rev 38915)
+++ branches/jbosstools-3.3.0.Beta1/build/publish.sh 2012-02-20 18:24:14 UTC (rev 38916)
@@ -321,9 +321,6 @@
#fi
fi
- # and create/replace a snapshot dir outside Hudson which is file:// accessible
- date; rsync -arzq --delete ${STAGINGDIR}/*
$INTRNALDEST/builds/staging/${JOB_NAME}.next
-
# and create/replace a snapshot dir w/ static URL
date; rsync -arzq --protocol=28 --delete ${STAGINGDIR}/*
$DESTINATION/builds/staging/${JOB_NAME}.next
@@ -405,6 +402,17 @@
echo $metadata >> ${STAGINGDIR}/all/compositeContent.xml
echo $metadata >> ${STAGINGDIR}/all/compositeArtifacts.xml
date; rsync -arzq --protocol=28 ${STAGINGDIR}/all/composite*.xml
$DESTINATION/builds/staging/${JOB_NAME}/all/
+
+ # create a snapshot dir outside Hudson which is file:// accessible
+ date; rsync -arzq --delete ${STAGINGDIR}/*
$INTRNALDEST/builds/staging/${JOB_NAME}.next
+
+ # cycle internal copy of ${JOB_NAME} in staging and staging.previous
+ # purge contents of /builds/staging.previous/${JOB_NAME} and remove empty dir
+ rm -fr $INTRNALDEST/builds/staging.previous/${JOB_NAME}/
+ # move contents of /builds/staging/${JOB_NAME} into
/builds/staging.previous/${JOB_NAME}
+ mv $INTRNALDEST/builds/staging/${JOB_NAME}
$INTRNALDEST/builds/staging.previous/${JOB_NAME}
+ # move contents of /builds/staging/${JOB_NAME}.next into /builds/staging/${JOB_NAME}
+ mv $INTRNALDEST/builds/staging/${JOB_NAME}.next
$INTRNALDEST/builds/staging/${JOB_NAME}
fi
# extra publish step for aggregate update sites ONLY