-
Notifications
You must be signed in to change notification settings - Fork 1
/
.travis.yml
59 lines (52 loc) · 2.4 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
language: node_js
node_js:
- "9"
matrix:
include:
- os: linux
dist: trusty
sudo: required
env:
- QUALITY=yes
- PROXY_VALIDATION=yes
- os: linux
dist: precise
sudo: required
- os: osx
osx_image: xcode7.2
allow_failures:
- os: osx
branches:
only: master
notifications:
webhooks: https://www.travisbuddy.com/?insertMode=update
before_script:
- if [[ $PROXY_VALIDATION == "yes" ]]; then mkdir -vp /home/travis/.ssh/; fi
- if [[ $PROXY_VALIDATION == "yes" ]]; then ssh-keygen -f /home/travis/.ssh/id_ecdsa -t ecdsa -N ''; fi
- if [[ $PROXY_VALIDATION == "yes" ]]; then cat /home/travis/.ssh/*.pub > /home/travis/.ssh/authorized_keys; fi
- if [[ $PROXY_VALIDATION == "yes" ]]; then chmod 600 /home/travis/.ssh/*; fi
- if [[ $PROXY_VALIDATION == "yes" ]]; then chmod 700 /home/travis/.ssh/.; fi
- if [[ $PROXY_VALIDATION == "yes" ]]; then ssh -f -o "StrictHostKeyChecking no" -D 9999 -q -N travis@localhost; fi
- travis_retry git clone -b gh-pages https://git@$GH_REPO_REF docs
- travis_retry npm install
- travis_retry npm install coveralls istanbul mocha chai codecov codacy-coverage mocha-lcov-reporter eslint jsdoc
- travis_retry npm install -g coveralls istanbul mocha chai codecov codacy-coverage mocha-lcov-reporter eslint jsdoc
- travis_retry sudo apt-get install tinyproxy curl
- if [[ $PROXY_VALIDATION == "yes" ]]; then tinyproxy; fi
- if [[ $PROXY_VALIDATION == "yes" ]]; then travis_retry curl -v -I --proxy socks://127.0.0.1:9999 https://www.google.com; fi
script:
- travis_retry npm run test
- if [[ $PROXY_VALIDATION == "yes" ]]; then export socks_proxy=socks4://127.0.0.1:9999; fi
- if [[ $PROXY_VALIDATION == "yes" ]]; then travis_retry npm run test; fi
- npm run lint
after_success:
- if [[ $QUALITY == "yes" ]]; then travis_retry npm run cover; fi
- if [[ $QUALITY == "yes" ]]; then travis_retry npm run coveralls; fi
- if [[ $QUALITY == "yes" ]]; then travis_retry npm run codecov; fi
- if [[ $QUALITY == "yes" ]]; then travis_retry npm run codacy; fi
- if [[ $QUALITY == "yes" ]]; then mv docs/docs.sh .; cd docs; rm -rvf ./*; mv ../docs.sh .; chmod +x docs.sh; ./docs.sh; fi
env:
global:
- GH_REPO_NAME: node-binance-api
- GH_REPO_REF: github.com/jaggedsoft/node-binance-api.git
- JSDOC_FILES: $TRAVIS_BUILD_DIR/node-binance-api.js