Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Williams2013-04-10 02:40:09 +0000
committerDavid Williams2013-04-10 02:40:24 +0000
commitd47c9ac583562a2b80f06e67283cc2736067fd71 (patch)
tree7029a465c76d2b32532db44998207ca0c7f45cd9 /production/publish-repo.sh
parent97ec9b1d7b13611713e3f8b295da83c5af7c400b (diff)
downloadeclipse.platform.releng.aggregator-d47c9ac583562a2b80f06e67283cc2736067fd71.tar.gz
eclipse.platform.releng.aggregator-d47c9ac583562a2b80f06e67283cc2736067fd71.tar.xz
eclipse.platform.releng.aggregator-d47c9ac583562a2b80f06e67283cc2736067fd71.zip
[releng] fix repo script
Diffstat (limited to 'production/publish-repo.sh')
-rw-r--r--production/publish-repo.sh24
1 files changed, 15 insertions, 9 deletions
diff --git a/production/publish-repo.sh b/production/publish-repo.sh
index a78141161..f5864ce25 100644
--- a/production/publish-repo.sh
+++ b/production/publish-repo.sh
@@ -49,22 +49,24 @@ function updateSiteOnBuildMachine()
# contrary to intuition (and previous behavior, bash 3.1) do NOT use quotes around right side of expression.
- if [[ "${eclipseStream}" =~ ([[:digit:]]*)\.([[:digit:]]*)\.([[:digit:]]*) ]]
+ if [[ "${STREAM}" =~ ([[:digit:]]*)\.([[:digit:]]*)\.([[:digit:]]*) ]]
then
eclipseStreamMajor=${BASH_REMATCH[1]}
eclipseStreamMinor=${BASH_REMATCH[2]}
eclipseStreamService=${BASH_REMATCH[3]}
else
- echo "eclipseStream, $eclipseStream, must contain major, minor, and service versions, such as 4.2.0" >&2
+ echo "STREAM, $STREAM, must contain major, minor, and service versions, such as 4.3.0" >&2
return 1
fi
siteDir=${ROOT}/siteDir
updatesSuffix="builds"
+
siteDirOnBuildMachine=$siteDir/updates/${eclipseStreamMajor}.${eclipseStreamMinor}-${buildType}-${updatesSuffix}/${BUILD_ID}
+
mkdir -p ${siteDirOnBuildMachine}
RC=$?
- if [[ RC != 0 ]]
+ if (( RC != 0 ))
then
echo "ERROR: could not create update site on build machine. RC: $RC"
echo " obtained error trying to create ${siteDirOnBuildMachine}"
@@ -75,9 +77,9 @@ function updateSiteOnBuildMachine()
}
siteDirOnBuildMachine=$( updateSiteOnBuildMachine "$BUILD_ROOT" "$BUILD_ID" "$STREAM" )
-
+echo "siteDirOnBuildMachine: ${siteDirOnBuildMachine}"
repositoryDir=${buildDirectory}/repository
-
+echo "repositoryDir: ${repositoryDir}"
# for now, straight copy from what was produced to local build machine directory.
# This is partially done so that
# rest of scripts stay common
@@ -92,10 +94,10 @@ if [[ -n "${repositoryDir}" && -d "${repositoryDir}" && -n "${siteDirOnBuildMach
then
rsync --times --omit-dir-times --recursive "${repositoryDir}/" "${siteDirOnBuildMachine}/"
RC=$?
- if [[ $RC != 0 ]]
+ if (( $RC != 0 ))
then
echo "ERROR: rsync of repo returned error. RC: $RC"
- echo " obtained while copying
+ echo " obtained while copying"
echo " from ${repositoryDir}"
echo " to ${siteDirOnBuildMachine}"
exit $RC
@@ -104,12 +106,16 @@ then
buildType=${BUILD_ID:0:1}
rsync --times --omit-dir-times --recursive "${EBuilderDir}/eclipse/publishingFiles/staticRepoSiteFiles/${buildType}builds/simple/" "${siteDirOnBuildMachine}/"
RC=$?
- if [[ $RC != 0 ]]
+ if (( $RC != 0 ))
then
echo "ERROR: rsync of repo returned error. RC: $RC"
- echo " obtained while copying
+ echo " obtained while copying"
echo " from ${EBuilderDir}/eclipse/publishingFiles/staticRepoSiteFiles/${buildType}builds/simple/"
echo " to ${siteDirOnBuildMachine}"
exit $RC
fi
+else
+ echo "ERROR: Some directory didn't exist for update site copy."
+ echo " repositoryDir: ${repositoryDir}"
+ echo " siteDirOnBuildMachine: ${siteDirOnBuildMachine}"
fi

Back to the top