Skip to content

Commit

Permalink
Merge pull request #246 from kiwix/fix-travis-nighlty-builds-and-tags
Browse files Browse the repository at this point in the history
Fix .travis.yml to generate packages for both nightly and tags.
  • Loading branch information
mossroy authored Jun 2, 2017
2 parents e4355cd + 5cfa7dc commit d37f971
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,10 @@ script:
- pkill node
deploy:
provider: script
script: "./scripts/setup_travis_env.sh && DISPLAY=:99.0 ./scripts/create_all_packages.sh"
# This deployment handles 2 different cases :
# - the nightly builds (launched by cron)
# - the generation of packages for public releases (launched by a tag)
# In both cases, we run the same script, but with different command-line arguments
script: if [ "${TRAVIS_TAG}aa" = "aa" ]; then CMD_ARGS=""; else CMD_ARGS="-t -v ${TRAVIS_TAG}"; fi && ./scripts/setup_travis_env.sh && DISPLAY=:99.0 ./scripts/create_all_packages.sh $CMD_ARGS
on:
condition: ( "$TRAVIS_EVENT_TYPE" = "cron" )
deploy:
provider: script
script: "./scripts/setup_travis_env.sh && DISPLAY=:99.0 ./scripts/create_all_packages.sh -t -v $TRAVIS_TAG"
on:
tags: true
condition: ( "$TRAVIS_EVENT_TYPE" = "cron" || "${TRAVIS_TAG}bb" != "bb" )

0 comments on commit d37f971

Please sign in to comment.