servatrice/.travis.yml
tooomm 1618e89c41 travis: remove unneeded debug builds on tags for faster release deployment (#3266)
* add hint

* enable condition for debug

* enable new conditions
2018-06-21 19:40:12 -04:00

102 lines
2.9 KiB
YAML

language: cpp
cache: ccache
conditions: v1
matrix:
fast_finish: true
include:
- os: linux
dist: trusty
group: stable
env: BUILDTYPE=Debug
if: tag IS NOT present
- os: linux
dist: trusty
group: stable
env: BUILDTYPE=Release
if: (branch = master AND NOT type = pull_request) OR tag IS present
- os: osx
osx_image: xcode8
env: BUILDTYPE=Debug
if: tag IS NOT present
- os: osx
osx_image: xcode8
env: BUILDTYPE=Release
if: (branch = master AND NOT type = pull_request) OR tag IS present
#install dependencies for container-based "linux" builds
addons:
apt:
sources:
- sourceline: 'deb http://apt.llvm.org/trusty/ llvm-toolchain-trusty-5.0 main'
key_url: 'http://llvm.org/apt/llvm-snapshot.gpg.key'
packages:
- bc
- clang-format-5.0
- cmake
- libprotobuf-dev
- protobuf-compiler
- qt5-default
- qttools5-dev
- qttools5-dev-tools
- qtmultimedia5-dev
- libqt5multimedia5-plugins
- libqt5svg5-dev
- libqt5sql5-mysql
before_install: bash ./.ci/travis-dependencies.sh
script: bash ./.ci/travis-compile.sh
# Builds for pull requests skip the deployment step altogether
deploy:
# Deploy configuration for "beta" releases
- provider: releases
api_key:
secure: mLMF41q7xgOR1sjczsilEy7HQis2PkZCzhfOGbn/8FoOQnmmPOZjrsdhn06ZSl3SFsbfCLuClDYXAbFscQmdgjcGN5AmHV+JYfW650QEuQa/f4/lQFsVRtEqUA1O3FQ0OuRxdpCfJubZBdFVH8SbZ93GLC5zXJbkWQNq+xCX1fU=
skip_cleanup: true
name: "Cockatrice $TRAVIS_TAG"
body: "Beta release of Cockatrice"
file_glob: true
file: "build/Cockatrice-*"
overwrite: true
draft: false
prerelease: true
on:
tags: true
repo: Cockatrice/Cockatrice
condition: $BUILDTYPE = Release && $TRAVIS_TAG =~ ([0-9]|[1-9][0-9])(\.([0-9]|[1-9][0-9])){2}-beta(\.([2-9]|[1-9][0-9]))?$ # regex to match semver naming convention for beta pre-releases
# Deploy configuration for "stable" releases
- provider: releases
api_key:
secure: mLMF41q7xgOR1sjczsilEy7HQis2PkZCzhfOGbn/8FoOQnmmPOZjrsdhn06ZSl3SFsbfCLuClDYXAbFscQmdgjcGN5AmHV+JYfW650QEuQa/f4/lQFsVRtEqUA1O3FQ0OuRxdpCfJubZBdFVH8SbZ93GLC5zXJbkWQNq+xCX1fU=
skip_cleanup: true
file_glob: true
file: "build/Cockatrice-*"
overwrite: true
draft: false
prerelease: false
on:
tags: true
repo: Cockatrice/Cockatrice
condition: $BUILDTYPE = Release && $TRAVIS_TAG =~ ([0-9]|[1-9][0-9])(\.([0-9]|[1-9][0-9])){2}$ # regex to match semver naming convention for stable full releases
notifications:
webhooks:
urls:
- https://webhooks.gitter.im/e/d94969c3b01b22cbdcb7
on_success: change
on_failure: change
on_start: never
on_cancel: change
on_error: change
# official validator for ".travis.yml" config file: https://yaml.travis-ci.org
# travis config documentation: https://docs.travis-ci.com/user/customizing-the-build