-
Notifications
You must be signed in to change notification settings - Fork 32
/
.travis.yml
93 lines (79 loc) · 2.51 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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
dist: trusty
sudo: required
language: scala
scala: 2.11.11
cache:
directories:
- $HOME/.sbt
- $HOME/.ivy2
services:
- docker
install:
- |
set -e
if [[ ${LANGUAGE} = python ]]; then
sudo apt install libxml2-dev curl build-essential
make build
cd python
pip install -e .
fi
before_script:
- make -f "$TRAVIS_BUILD_DIR/Makefile" docker-bblfsh
- make -f "$TRAVIS_BUILD_DIR/Makefile" docker-bblfsh-install-drivers
script:
- if [[ ${LANGUAGE} = python ]]; then make test ;fi
- |
set -e
if [[ ${LANGUAGE} = java ]]; then
make travis-test
bash <(curl -s https://codecov.io/bash)
fi
jobs:
include:
- {env: 'LANGUAGE=java SPARK_VERSION=2.2.1', jdk: openjdk8}
- {env: 'LANGUAGE=java SPARK_VERSION=2.3.1', jdk: openjdk8}
- {env: 'LANGUAGE=python SPARK_VERSION=2.3.1', python: 3.4, language: python}
- {env: 'LANGUAGE=python SPARK_VERSION=2.3.1', python: 3.5, language: python}
- {env: 'LANGUAGE=python SPARK_VERSION=2.2.1', python: 3.6, language: python}
- {env: 'LANGUAGE=python SPARK_VERSION=2.3.1', python: 3.6, language: python}
- stage: deploy
if: tag IS present OR (branch = master AND env(TRAVIS_PULL_REQUEST) IS present)
jdk: openjdk8
install: skip
before_script: skip
script:
- openssl aes-256-cbc -K $encrypted_8a9ac81f2640_key -iv $encrypted_8a9ac81f2640_iv -in key.asc.enc -out key.asc -d
- gpg --no-default-keyring --primary-keyring ./project/.gnupg/pubring.gpg --secret-keyring ./project/.gnupg/secring.gpg --keyring ./project/.gnupg/pubring.gpg --fingerprint --import key.asc
- make build
- cp target/jgit-spark-connector-uber.jar "jgit-spark-connector-$TRAVIS_TAG.jar"
- make docker-push
deploy:
- provider: script
script: make maven-release
skip_cleanup: true
on:
tags: true
- provider: releases
api_key:
secure: $GITHUB_TOKEN
file_glob: true
file: "*.jar"
skip_cleanup: true
on:
tags: true
- if: tag IS present
language: python
python: 3.6
script:
- sudo apt install libxml2-dev curl build-essential
- make build
- cd python
- pip install -e .
- echo "$TRAVIS_TAG" | cut -c 2- > version.txt
deploy:
- provider: pypi
user: $PYPI_USERNAME
password: $PYPI_PASSWORD
skip_cleanup: true
on:
tags: true