#
# Required environment variables in the travis config
#
# DOCKER_USERNAME
#
language: cpp

git:
  submodules: false

stages:
  - name: Build Qbs and and run autotests

jobs:
  include:
    - &build-on-stretch
      stage: Build Qbs and and run autotests
      name: With Qbs on Debian stretch (linux_amd64)
      env:
        SERVICE=stretch
      services:
        - docker
      before_install:
        - docker-compose pull ${SERVICE}
      script:
        - docker-compose run --rm ${SERVICE} scripts/build-qbs-with-qbs.sh

    - <<: *build-on-stretch
      name: With QMake on Debian stretch (linux_amd64)
      script:
        - docker-compose run --rm ${SERVICE} scripts/build-qbs-with-qmake.sh

Enable Travis CI to build and test Qbs
Enable Travis CI to build and test Qbs

This patch adds a configuration file for building and testing Qbs with Travis
CI. Travis supports Linux, Windows and Mac OS. It requires a repository on
github, but is generally free for open source projects. Users could simply fork
Qbs, connect their Travis account to the forked repository and let it build.

In addition to this patch, a bot has been implemented that watches
codereview.qt-project.org for changes. Whenever a user uploads a new change or
patch set, the bot pushes this change to a mirror repository on github and kicks
Travis to build it. Once the build has finished the result is posted as a
comment back to gerrit.

This bot could be extended to behave like the Qt CI system.

Change-Id: Ic0e1bd507171f40860bfe352651880b4ae7412fc
Reviewed-by: Qbs CI Bot <94eb2064b2abdc395eb337a66643921d92d5d1fb@weickelt.de>
Reviewed-by: Christian Kandeler <3aa99dcdd3f0cac61fb81c2a11771c0cc2497607@qt.io>
