forked from Croydon/nodegit
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
119 lines (100 loc) · 4.96 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
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
sudo: false
branches:
only:
- master
- /^v\d+\.\d+\.\d+$/
compiler: clang
language: node_js
# Stage order; the default stage is "test", which in our case is actually building and deploying
stages:
- "Extended testing"
- test
- "Deploy documentation"
env:
- TARGET_ARCH="x64"
- TARGET_ARCH="ia32"
node_js:
- "9"
- "8"
- "6"
os:
- linux
- osx
jobs:
exclude:
- os: osx
env: TARGET_ARCH="ia32"
include:
- stage: "Extended testing"
os: linux
node_js: "8"
env: TARGET_ARCH="x64" EXTENDED_TESTING="false"
- stage: "Deploy documentation"
os: linux
node_js: "8"
env: TARGET_ARCH="x64" DEPLOY_DOCUMENTATION="true"
git:
depth: 5
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- build-essential
- libssl-dev
- gcc-4.9-multilib
- g++-4.9-multilib
- lcov
before_install:
- export CC=clang
- export CXX=clang++
- export npm_config_clang=1
- export JOBS=4
- if [ -z "$TRAVIS_TAG" ] && [ "$EXTENDED_TESTING" == "true" ]; then
export GYP_DEFINES="coverage=1 use_obsolete_asm=true";
export CC=/usr/bin/gcc-4.9;
export CXX=/usr/bin/g++-4.9;
export npm_config_clang=0;
wget http://downloads.sourceforge.net/ltp/lcov-1.10.tar.gz;
tar xvfz lcov-1.10.tar.gz;
else
export GYP_DEFINES="use_obsolete_asm=true";
fi
install:
- travis_retry npm install;
# This is a random private key used purely for testing.
before_script:
- echo -e "Host *\n\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 ~/.ssh/id_rsa*
- eval `ssh-agent -s`
- ssh-add ~/.ssh/id_rsa
- git config --global user.name "John Doe"
- git config --global user.email [email protected]
script:
if [ -z "$TRAVIS_TAG" ] && [ "$EXTENDED_TESTING" == "true" ]; then
travis_retry npm test && npm run cov && npm run coveralls;
else
travis_retry npm test;
fi
after_success:
- if [ -n "$TRAVIS_TAG" ] && [ "$EXTENDED_TESTING" != "true" ] && [ "$DEPLOY_DOCUMENTATION" != "true" ]; then
npm install -g node-pre-gyp;
npm install -g aws-sdk;
node lifecycleScripts/clean;
node-pre-gyp package --target_arch=$TARGET_ARCH;
node-pre-gyp publish --target_arch=$TARGET_ARCH;
fi
- if [ "$TRAVIS_PULL_REQUEST" == "false" ] && [ -n "$TRAVIS_TAG" ] && [ "$DEPLOY_DOCUMENTATION" == "true" ]; then
.travis/deploy-docs.sh;
fi
notifications:
slack:
secure: KglNSqZiid9YudCwkPFDh+sZfW5BwFlM70y67E4peHwwlbbV1sSBPHcs74ZHP/lqgEZ4hMv4N2NI58oYFD5/1a+tKIQP1TkdIMuq4j2LXheuirA2HDcydOVrsC8kRx5XFGKdVRg/uyX2dlRHcOWFhxrS6yc6IxtxYWlRTD2SmEc=
webhooks:
urls:
- https://webhooks.gitter.im/e/cbafdb27ad32ba746a73
on_success: always # options: [always|never|change] default: always
on_failure: always # options: [always|never|change] default: always
on_start: false # default: false