mate-control-center/.travis.yml

76 lines
2.2 KiB
YAML
Raw Normal View History

2019-02-01 18:49:55 +02:00
# vim: set ts=2 sts=2 sw=2 expandtab :
dist: focal
2020-04-06 09:08:17 +03:00
language: shell
os: linux
2019-02-01 18:49:55 +02:00
services:
- docker
2020-04-06 09:08:17 +03:00
addons:
apt:
packages:
- python3-pip
- python3-setuptools
2019-02-01 18:49:55 +02:00
2019-03-12 10:46:20 +02:00
branches:
except:
- gh-pages
2019-02-01 18:49:55 +02:00
before_install:
2019-02-07 15:21:50 +02:00
- curl -Ls -o docker-build https://github.com/mate-desktop/mate-dev-scripts/raw/master/travis/docker-build
2019-03-12 10:46:20 +02:00
- curl -Ls -o gen-index https://github.com/mate-desktop/mate-dev-scripts/raw/master/travis/gen-index.sh
- chmod +x docker-build gen-index
2019-03-13 11:00:23 +02:00
2019-02-01 18:49:55 +02:00
install:
- pip3 install PyGithub
- ./docker-build --name ${DISTRO} --config .build.yml --install
2019-02-01 18:49:55 +02:00
script:
- ./docker-build --name ${DISTRO} --verbose --config .build.yml --build scripts
2019-03-12 10:46:20 +02:00
notifications:
irc:
if: (tag OR branch = master) AND
repo = "mate-desktop/mate-control-center"
channels:
- "irc.libera.chat#mate-dev"
template:
- "[%{repository_name}] %{author}: %{commit_subject}"
- "[%{branch}] %{commit} %{message} %{build_url}"
on_success: never
on_failure: always
2019-03-12 10:46:20 +02:00
deploy:
2019-03-13 11:00:23 +02:00
- provider: pages
2020-04-06 09:08:17 +03:00
edge: true
token: $GITHUB_TOKEN
keep_history: false
committer_from_gh: true
target_branch: gh-pages
local_dir: html-report
strategy: git
2019-03-13 11:00:23 +02:00
on:
all_branches: true
condition: ${DISTRO} =~ ^fedora.*$
- provider: script
2020-04-06 09:08:17 +03:00
edge: true
script: ./docker-build --verbose --config .build.yml --release github
2019-03-13 11:00:23 +02:00
on:
tags: true
condition: "${TRAVIS_TAG} =~ ^v.*$ && ${DISTRO} =~ ^fedora.*$"
2019-03-12 10:46:20 +02:00
after_success:
- 'if [[ "$TRAVIS_SECURE_ENV_VARS" == "true" && "$TRAVIS_PULL_REQUEST" != "false" && ${DISTRO} =~ ^fedora.*$ ]]; then
REPO_SLUG_ARRAY=(${TRAVIS_REPO_SLUG//\// });
REPO_NAME=${REPO_SLUG_ARRAY[1]};
URL="https://${REPO_NAME}.mate-desktop.dev";
COMMENT="Code analysis completed";
curl -H "Authorization: token $GITHUB_TOKEN" -X POST
-d "{\"state\": \"success\", \"description\": \"$COMMENT\", \"context\":\"scan-build\", \"target_url\": \"$URL\"}"
https://api.github.com/repos/${TRAVIS_REPO_SLUG}/statuses/${TRAVIS_PULL_REQUEST_SHA};
fi'
2019-02-01 18:49:55 +02:00
env:
# - DISTRO="archlinux:latest"
- DISTRO="debian:testing"
2019-11-24 18:06:30 +02:00
- DISTRO="fedora:latest"
# - DISTRO="ubuntu:rolling"