Skip to content
Snippets Groups Projects
Commit 124777aa authored by david_williams's avatar david_williams
Browse files

add pack200 to promote script

parent dd8549c7
No related branches found
No related tags found
No related merge requests found
#!/usr/bin/env bash
# use of this script requires our WTP addRepoProperties app to have already been added to eclipse instance.
# TODO: we could probably integrate and always call 'install-relengTools.sh' for ease? safety?
APP_NAME=org.eclipse.wtp.releng.tools.addRepoProperties
devworkspace=./workspace
JAVA_5_HOME=/shared/webtools/apps/ibm-java2-sdk-5.0-12.1-linux-i386
JAVA_6_HOME=/shared/webtools/apps/ibm-java-sdk-6.0-8.1-linux-i386
export JAVA_HOME=${JAVA_6_HOME}
devJRE=$JAVA_HOME/jre/bin/java
ibmDevArgs="-Xms128M -Xmx256M -Dosgi.ws=gtk -Dosgi.os=linux -Dosgi.arch=x86"
#REPO="/shared/webtools/committers/wtp-R3.3.0-I/20101209114749/S-3.3.0M4-20101209114749/repository"
#BUILD_BRANCH=R3.3.0
#BUILD_ID=S-3.3.0M4-20101209114749
#STATS_TAG_SUFFIX=_indigo_M4
REPO=$1
BUILD_BRANCH=$2
BUILD_ID=$3
STATS_TAG_SUFFIX=$4
if [[ -z REPO ]]
then
echo "ERROR: this script requires a repository to add properties to.";
exit 1;
fi
echo "BUILD_BRANCH: ${}
if [[ \( ! \( -z "${BUILD_BRANCH"} \) \) -a \( ! \( -z "${BUILD_ID}" \) \) ]]
then
MIRRORURL="/webtools/downloads/drops/${BUILD_BRANCH}/${BUILD_ID}/repository/"
else
echo "WARNING: no mirror URL specified.";
MIRRORURL=""
fi
if [ ! -z $MIRRORURL ]
then
MIRRORURL_ARG="http://www.eclipse.org/downloads/download.php?format=xml&file=${MIRRORURL}&protocol=http"
else
MIRRORURL_ARG=""
fi
# remember, the '&' should NOT be unescaped here ... the p2 api (or underlying xml) will escape it.
devArgs="$ibmDevArgs \
-Dp2MirrorsURL=${MIRRORURL_ARG} \
-DartifactRepoDirectory=${REPO} \
-Dp2StatsURI=http://download.eclipse.org/stats/webtools/repository/indigo -DstatsArtifactsSuffix="${STATS_TAG_SUFFIX}" -DstatsTrackedArtifacts=org.eclipse.wst.jsdt.feature,org.eclipse.wst.xml_ui.feature,org.eclipse.wst.web_ui.feature,org.eclipse.jst.enterprise_ui.feature"
echo "dev: " $0
echo
echo "devworkspace: " $devworkspace
echo
echo "devJRE: " $devJRE
echo
echo "devArgs: " $devArgs
echo
echo "APP_NAME: " $APP_NAME
$devJRE -version
echo
ECLIPSE_INSTALL=/shared/webtools/apps/eclipse361/eclipse
$ECLIPSE_INSTALL/eclipse -debug -nosplash -consolelog -console -data $devworkspace --launcher.suppressErrors -application ${APP_NAME} ${OTHER_ARGS} -vm $devJRE -vmargs $devArgs
#!/usr/bin/env bash
APP_NAME=org.eclipse.equinox.p2.director
OTHER_ARGS="-metadataRepository http://download.eclipse.org/webtools/releng/repository/ -artifactRepository http://download.eclipse.org/webtools/releng/repository/ -installIU org.eclipse.wtp.releng.tools.feature.feature.group"
devworkspace=~/workspace-addRepoProperties
JAVA_5_HOME=/shared/webtools/apps/ibm-java2-sdk-5.0-12.1-linux-i386
JAVA_6_HOME=/shared/webtools/apps/ibm-java-sdk-6.0-8.1-linux-i386
export JAVA_HOME=${JAVA_6_HOME}
devJRE=$JAVA_HOME/jre/bin/java
ibmDevArgs="-Xms128M -Xmx256M -Dosgi.ws=gtk -Dosgi.os=linux -Dosgi.arch=x86"
devArgs=$ibmDevArgs
echo "dev: " $0
echo
echo "devworkspace: " $devworkspace
echo
echo "devJRE: " $devJRE
echo "OTHER_ARGS: " ${OTHER_ARGS}
echo
$devJRE -version
echo
ECLIPSE_INSTALL=/shared/webtools/apps/eclipse361/eclipse
$ECLIPSE_INSTALL/eclipse -nosplash -console -data $devworkspace -application ${APP_NAME} ${OTHER_ARGS} -vm $devJRE -vmargs $devArgs
...@@ -10,7 +10,8 @@ function usage() { ...@@ -10,7 +10,8 @@ function usage() {
printf "\n\t\t%s\t%s" "-d" "delete old builds" >&2 printf "\n\t\t%s\t%s" "-d" "delete old builds" >&2
printf "\n\t\t%s\t%s" "-s" "send notification mail" >&2 printf "\n\t\t%s\t%s" "-s" "send notification mail" >&2
printf "\n\t\t%s\t%s" "-c" "copy the build from committers to downloads" >&2 printf "\n\t\t%s\t%s" "-c" "copy the build from committers to downloads" >&2
printf "\n\t\t%s\t%s" "-z" "process artifacts (create pack200 gz jars, etc.) Remember, is long running." >&2 printf "\n\t\t%s\t%s" "-z" "process artifacts (create pack200 gz jars, etc.) Remember, is long running" >&2
printf "\n\t\t%s\t%s" "-a" "add properties" >&2
printf "\n\t\t%s\t%s\n" "-h" "this help message" >&2 printf "\n\t\t%s\t%s\n" "-h" "this help message" >&2
} }
...@@ -21,7 +22,8 @@ deleteOld= ...@@ -21,7 +22,8 @@ deleteOld=
doCopy= doCopy=
projectname= projectname=
processArtifacts= processArtifacts=
while getopts 'hvdcszp:' OPTION addProperties=
while getopts 'hvdcszap:' OPTION
do do
case $OPTION in case $OPTION in
h) usage h) usage
...@@ -36,6 +38,8 @@ do ...@@ -36,6 +38,8 @@ do
s) sendmail=1 s) sendmail=1
;; ;;
z) processArtifacts=1 z) processArtifacts=1
;;
a) addProperties=1
;; ;;
p) projectname=$OPTARG p) projectname=$OPTARG
;; ;;
...@@ -93,7 +97,7 @@ fi ...@@ -93,7 +97,7 @@ fi
if [ ! \( -d ${promoteProjectDir} \) ] if [ ! \( -d ${promoteProjectDir} \) ]
then then
printf "\n\t%s\n" "Error: directory ${promoteProjectDir} does not exist." >&2 printf "\n\t%s\n" "ERROR: directory ${promoteProjectDir} does not exist." >&2
usage usage
exit 4 exit 4
fi fi
...@@ -180,6 +184,15 @@ then ...@@ -180,6 +184,15 @@ then
fi fi
fi fi
# TODO: we currently do not add properties to tests repo ... maybe should? for mirror URL, at least.
# TODO: a fourth argument can be specified to provide stats suffix
# such as _helios_SR2, _indigo_SR0 ... but, takes some customization updated fairly often, to be accurate.
if [[ addProperties -a \( -d "${repoDirLocation}" \) ]]
then
${RELENG_CONTROL}/addRepoProperties.sh "${repoDirLocation}" "${buildBranch}" "${dropDirName}"
fi
if [ "patches" == $distribution ] if [ "patches" == $distribution ]
then then
TODIR=${DOWNLOAD_ROOT}/webtools/patches/drops/${buildBranch}/ TODIR=${DOWNLOAD_ROOT}/webtools/patches/drops/${buildBranch}/
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment