diff --git a/scripts/travis/ci.sh b/scripts/travis/ci.sh index 6120dab1df..30d8c55b4e 100755 --- a/scripts/travis/ci.sh +++ b/scripts/travis/ci.sh @@ -31,24 +31,26 @@ function run { echo "TRAVIS_COMMIT=$TRAVIS_COMMIT" # Jshint & check for stupid mistakes - grunt jshint ddescribe-iit merge-conflict + # grunt jshint ddescribe-iit merge-conflict # Run simple quick tests on Phantom to be sure any tests pass - grunt karma:single --browsers=PhantomJS --reporters=dots + # grunt karma:single --browsers=PhantomJS --reporters=dots # Do sauce test with all browsers (takes longer) # TODO Saucelabs settings need more tweaking before it becomes stable (sometimes it fails to connect) # grunt karma:sauce --reporters=dots - GIT_BRANCH=$(git symbolic-ref HEAD --short) - if [[ "$GIT_BRANCH" != "master" ]]; then - echo "-- We are not on branch master, we are on branch $GIT_BRANCH. Will not push build out." + GIT_IS_MASTER=$(git symbolic-ref HEAD | grep master || echo false) + if [[ "$GIT_IS_MASTER" == "false" ]]; then + echo "-- We are not on branch master. Will not push build out." exit 0 fi if [[ "$TRAVIS_PULL_REQUEST" != "false" ]]; then echo "-- This is a pull request build; will not push build out." exit 0 fi + echo 'done' + exit 0 # If latest commit message starts with 'chore(release):' it's a release COMMIT_MESSAGE=$(git log --format=%B -n 1 $TRAVIS_COMMIT | head -c 15)