From fb15c8477e178abeb72e196f77da168e956768bf Mon Sep 17 00:00:00 2001 From: "Rafael G. Martins" Date: Wed, 6 Apr 2016 01:04:43 +0200 Subject: travis: trying to fix deploy --- .travis.yml | 15 +++------------ build-aux/travis-deploy.sh | 15 +++++++++++++++ 2 files changed, 18 insertions(+), 12 deletions(-) diff --git a/.travis.yml b/.travis.yml index cd2d134..0ea174c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -35,15 +35,6 @@ install: gem install ronn before_script: ./autogen.sh -script: ./build-aux/travis-build.sh - -deploy: - provider: script - script: ./build-aux/travis-deploy.sh - skip_cleanup: true - on: - repo: blogc/blogc - branch: master - condition: - - $CC = gcc - - $TARGET != valgrind +script: + - ./build-aux/travis-build.sh + - ./build-aux/travis-deploy.sh diff --git a/build-aux/travis-deploy.sh b/build-aux/travis-deploy.sh index 71469ff..0ef28bf 100755 --- a/build-aux/travis-deploy.sh +++ b/build-aux/travis-deploy.sh @@ -2,6 +2,21 @@ set -e +if [[ "x${TRAVIS_PULL_REQUEST}" != "xfalse" ]]; then + echo "This is a pull request. skipping deploy ..." + exit 0 +fi + +if [[ "x${TRAVIS_BRANCH}" != "xmaster" ]] && [[ "x${TRAVIS_TAG}" != xv* ]]; then + echo "This isn't master branch nor a valid tag. skipping deploy ..." + exit 0 +fi + +if [[ "x${CC}" != "xgcc" ]] || [[ "x${TARGET}" = "xvalgrind" ]]; then + echo "Invalid target for deploy. skipping ..." + exit 0 +fi + if [[ ! -d build ]]; then echo "Build directory not found." exit 1 -- cgit v1.2.3-18-g5258