blob: ee4c71313a9af58df6e185ea582e75b6ce5de78b [file] [log] [blame]
Stephan Herrmann288c70c2018-06-28 21:25:30 +02001# OPTIONAL VARIABLES TO BE SUPPLIED VIA ENV:
2# SIGN (unset or nosign)
3# PROMOTE (unset or false or target directory)
4
5BASE=`pwd`
6
7# ABSOLUTE PATHS:
8export ECOTJ_BASE=/home/data/httpd/download.eclipse.org/objectteams/ecotj
9
10
11OTDTVERSION=`cat ${BASE}/testrun/build-root/src/finalFeaturesVersions.properties|grep "objectteams.otdt="|cut -d '=' -f 2`
12if [ "${OTDTVERSION}" == "" ]
13then
14 echo "finalFeaturesVersions.properties not found, maybe build hasn't run successfully?"
15 exit 3
16fi
17echo "OTDTVERSION is $OTDTVERSION"
18
19# FIXME:
20ECOTJ_DIR=${BASE}/testrun/ecj/I-2.6.0-201806120848
21
22echo "====Step 1: request signing ===="
23cd ${ECOTJ_DIR}
24ECOTJ_JAR=`ls ecotj-*[0-9].jar`
25echo "ecotj is ${ECOTJ_JAR}"
26
27ECOTJ_NAME="ecotj-${BUILDTYPE}-${OTDTVERSION}"
28echo "ecotj name = ${ECOTJ_NAME}"
29
30curl -o ${ECOTJ_NAME}-signed.jar -F file=@${ECOTJ_JAR} http://build.eclipse.org:31338/sign
31
32echo "Signing completed"
33
34
35echo "====Step 2: upload ===="
36
37if [ "${PROMOTE}" != "false" ]
38then
39 cp ${ECOTJ_JAR} ${ECOTJ_BASE}/${ECOTJ_NAME}.jar
40 cp ${ECOTJ_NAME}-signed.jar ${ECOTJ_BASE}/
41 ls -latr ${ECOTJ_BASE}
42fi
43echo "====DONE===="