sudo: required
language: none

services:
  - docker

matrix:
  include:
    - env: CI_TARGET=debug

    - env: CI_TARGET=release
      after_success: touch build-release/doc/html/.nojekyll
      deploy:
        provider: pages
        skip_cleanup: true
        github_token: $GITHUB_TOKEN
        local_dir: build-release/doc/html
        on:
          branch: master

    - env: CI_TARGET=coverage
      after_success: bash <(curl -s https://codecov.io/bash) -g "*/test/*"

    - env: CI_TARGET=lint

before_install:
  - sudo apt-get update

install:
  - sudo apt-get install -y bash curl

before_script:
  - docker build -t worker $TRAVIS_BUILD_DIR/.ci

script:
  - docker run
    -u "$(id -u):$(id -g)"
    -w /workspace
    -v $TRAVIS_BUILD_DIR:/workspace
    worker .ci/$CI_TARGET.sh

sudo: required
language: none

services:
  - docker

matrix:
  include:
    - env: CI_DISTRO=xenial CI_TARGET=debug
    - env: CI_DISTRO=bionic CI_TARGET=debug

    - env: CI_DISTRO=xenial CI_TARGET=release
    - env: CI_DISTRO=bionic CI_TARGET=release
      after_success: touch build-release/doc/html/.nojekyll
      deploy:
        provider: pages
        skip_cleanup: true
        github_token: $GITHUB_TOKEN
        local_dir: build-release/doc/html
        on:
          branch: master

    - env: CI_DISTRO=xenial CI_TARGET=coverage
      after_success: bash <(curl -s https://codecov.io/bash) -g "*/test/*"

    - env: CI_DISTRO=xenial CI_TARGET=lint
    - env: CI_DISTRO=bionic CI_TARGET=lint

before_install:
  - sudo apt-get update

install:
  - sudo apt-get install -y bash curl

before_script:
  - docker build
    -t worker
    -f $TRAVIS_BUILD_DIR/.ci/Dockerfile.$CI_DISTRO
    $TRAVIS_BUILD_DIR/.ci

script:
  - docker run
    -u "$(id -u):$(id -g)"
    -w /workspace
    -v $TRAVIS_BUILD_DIR:/workspace
    worker .ci/$CI_TARGET.sh

Add Travis config for Bionic
Add Travis config for Bionic
