blob: 26f89c693ee0d24e4906d6c6215a9ffefe78d36a [file] [log] [blame]
Michael Ernst648d3de2015-12-11 11:48:55 -08001#!/bin/bash
2ROOT=$TRAVIS_BUILD_DIR/..
3
Michael Ernstcfbcb072015-12-11 18:46:59 -08004# Fail the whole script if any command fails
5set -e
6
Michael Ernstced5a712016-02-11 13:52:05 -08007export SHELLOPTS
8
Werner Dietl29448422016-11-20 17:05:39 -05009SLUGOWNER=${TRAVIS_REPO_SLUG%/*}
Werner Dietl1998e222017-04-16 18:06:51 -070010if [[ "$SLUGOWNER" == "" ]]; then
11 SLUGOWNER=typetools
12fi
13
Werner Dietl29448422016-11-20 17:05:39 -050014
Michael Ernst648d3de2015-12-11 11:48:55 -080015# jsr308-langtools
Michael Ernstced5a712016-02-11 13:52:05 -080016if [ -d ../jsr308-langtools ] ; then
17 (cd ../jsr308-langtools && hg pull && hg update)
18else
Michael Ernst4511a292016-11-27 07:25:24 -080019 set +e
20 echo "Running: hg identify https://bitbucket.org/${SLUGOWNER}/jsr308-langtools &>-"
21 hg identify https://bitbucket.org/${SLUGOWNER}/jsr308-langtools &>-
Michael Ernst1db57692016-11-27 08:09:59 -080022 if [ "$?" -ne 0 ]; then
23 SLUGOWNER=typetools
Michael Ernst4511a292016-11-27 07:25:24 -080024 fi
25 set -e
Michael Ernst1db57692016-11-27 08:09:59 -080026 echo "Running: (cd .. && hg clone https://bitbucket.org/${SLUGOWNER}/jsr308-langtools)"
27 (cd .. && (hg clone https://bitbucket.org/${SLUGOWNER}/jsr308-langtools || hg clone https://bitbucket.org/${SLUGOWNER}/jsr308-langtools))
28 echo "... done: (cd .. && hg clone https://bitbucket.org/${SLUGOWNER}/jsr308-langtools)"
Michael Ernstced5a712016-02-11 13:52:05 -080029fi
30(cd ../jsr308-langtools/ && ./.travis-build-without-test.sh)
Michael Ernst648d3de2015-12-11 11:48:55 -080031
Michael Ernst0bbe3872016-11-27 06:57:12 -080032## Compile
33echo "running \"ant compile\" for annotation-tools"
Michael Ernst648d3de2015-12-11 11:48:55 -080034ant compile