Merge "Force scala 2.11.6 for Ubuntu Trusty" into stable/mitaka

This commit is contained in:
Jenkins 2016-12-05 10:55:41 +00:00 committed by Gerrit Code Review
commit dda715c8f2
1 changed files with 9 additions and 4 deletions

View File

@ -17,11 +17,16 @@ if [ "$RETURN_CODE" != "200" ]; then
echo "http://www.scala-lang.org is unreachable" && exit 1
fi
VERSION="$(curl -s --fail http://www.scala-lang.org|grep 'scala-version'|grep -Eo '([0-9]\.?)+')"
if [ $? != 0 -o -z "${VERSION}" ]; then
echo "Installing default version $DEF_VERSION"
if [ "trusty" == "${DIB_RELEASE}" ]; then
# scala >= 2.12 for ubuntu depends on openjdk-8, not available on trusty
VERSION=${DEF_VERSION}
else
VERSION="$(curl -s --fail http://www.scala-lang.org|grep 'scala-version'|grep -Eo '([0-9]\.?)+')"
if [ $? != 0 -o -z "${VERSION}" ]; then
echo "Installing default version $DEF_VERSION"
VERSION=${DEF_VERSION}
fi
fi
PKG=scala-${VERSION}