forked from linkedin/coral
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
39 lines (29 loc) · 1.21 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
# More details on how to configure the Travis build
# https://docs.travis-ci.com/user/customizing-the-build/
language: java
jdk:
- openjdk8
#Skipping install step to avoid having Travis run arbitrary './gradlew assemble' task
# https://docs.travis-ci.com/user/customizing-the-build/#Skipping-the-Installation-Step
install:
- true
# We need to checkout origin/master for Spotless ratchetFrom functionality,
# so remove the --depth clone argument since it implies --single-branch.
git:
depth: false
#Don't build tags
branches:
except:
- /^v\d/
#Build and perform release (if needed)
script:
# 1. Print output every minute to avoid travis timeout
- while sleep 1m; do echo "=====[ $SECONDS seconds elapsed -- still running ]====="; done &
# 2. To validate changes, we run building and bintray upload in dry run. This happens on every build, even PRs.
# To publish, we perform github release and perform bintray upload (no dry run). This only for main branch builds.
- >
./gradlew build bintrayUpload --s -PbintrayDryRun
&& if [ "$TRAVIS_PULL_REQUEST" = "false" ] && [ "$TRAVIS_BRANCH" = "master" ];
then ./gradlew githubRelease bintrayUpload --s; fi
# 3. Killing background sleep loop
- kill %1