forked from dlsc-software-consulting-gmbh/CalendarFX
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
68 lines (56 loc) · 1.72 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
language: java
# to make the build work with oraclejdk8: https://travis-ci.community/t/solved-oraclejdk8-installation-failing-still-again/3428
dist: trusty
sudo: false # Linux OS: run in container
env:
global:
# get all the branches referencing this commit
- TAG_BRANCH=$(git ls-remote origin | sed -n "\|$TRAVIS_COMMIT\s\+refs/heads/|{s///p}")
# Necessary environment variables on Travis CI:
#
# GITHUB_TOKEN: Token from here: https://github.com/settings/tokens => with scope "public_repo"
# BINTRAY_USER: Bintray username
# BINTRAY_API_KEY: API key from here: https://bintray.com/profile/edit => API Key
#
# The Bintray URL follows the following pattern: https://bintray.com/subject/repo/package
# BINTRAY_SUBJECT=subject
# BINTRAY_REPO=repo
# BINTRAY_PACKAGE=package
jdk: oraclejdk8
addons:
apt:
packages:
- p7zip-full
before_install:
- if [[ "${TRAVIS_OS_NAME}" == linux ]]; then export DISPLAY=:99.0; sh -e /etc/init.d/xvfb start; fi
install: true
cache:
directories:
- $HOME/.m2
script: mvn test -B
after_success:
- chmod +x .github/deploy_prepare.sh
- chmod +x .github/deploy_bintray_central.sh
deploy:
- provider: script
script: .github/deploy_prepare.sh
skip_cleanup: true
on: &on
repo: $TRAVIS_REPO_SLUG
tags: true
all_branches: true
condition: $TAG_BRANCH =~ ^(master|master-11)$
- provider: releases
api_key: $GITHUB_TOKEN
file_glob: true
file:
- javadoc.zip
- /**/target/*.jar
skip_cleanup: true
name: Release $TRAVIS_TAG
body: See [CHANGELOG.md](https://github.com/$TRAVIS_REPO_SLUG/blob/$TAG_BRANCH/CHANGELOG.md)
on: *on
- provider: script
script: .github/deploy_bintray_central.sh
skip_cleanup: true
on: *on