diff options
-rwxr-xr-x | travis/detect-what-to-build.sh | 4 | ||||
-rwxr-xr-x | travis/travis.sh | 3 |
2 files changed, 4 insertions, 3 deletions
diff --git a/travis/detect-what-to-build.sh b/travis/detect-what-to-build.sh index 3119e01ef61..4387b6e4334 100755 --- a/travis/detect-what-to-build.sh +++ b/travis/detect-what-to-build.sh @@ -16,9 +16,9 @@ FILES=$(for C in $COMMITS; do JSON=$(curl -sLf https://api.github.com/repos/$TRA if [[ -z $FILES ]]; then SHOULD_BUILD=all -elif ! grep -v -E "(.h|.hh|.hxx|.c|.cpp|.cxx)$" <<< "$FILES"; then +elif ! grep -v -E "(.h|.hh|.hxx|.c|.cpp|.cxx)$" <<< "$FILES" &> /dev/null; then SHOULD_BUILD=cpp -elif ! grep -v -E "(.java)$" <<< "$FILES"; then +elif ! grep -v -E "(.java)$" <<< "$FILES" &> /dev/null; then SHOULD_BUILD=java else SHOULD_BUILD=all diff --git a/travis/travis.sh b/travis/travis.sh index 3ed81d1864b..1ea4d43dd66 100755 --- a/travis/travis.sh +++ b/travis/travis.sh @@ -14,5 +14,6 @@ DOCKER_IMAGE=vespaengine/vespa-build-centos7:latest bell & docker run --rm -v ${HOME}/.m2:/root/.m2 -v ${HOME}/.ccache:/root/.ccache -v $(pwd):/source \ - --entrypoint /source/travis/travis-build.sh ${DOCKER_IMAGE} + -e TRAVIS_REPO_SLUG=$TRAVIS_REPO_SLUG -e TRAVIS_PULL_REQUEST=$TRAVIS_PULL_REQUEST \ + --entrypoint /source/travis/travis-build.sh ${DOCKER_IMAGE} exit $? |