-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
38 lines (38 loc) · 1.16 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
language: node_js
matrix:
include:
- node_js: node # Current
env: BUILD_DOCS=true REPORT_COVERAGE=true
- node_js: lts/* # Latest LTS
env: NPM_DEPLOY=true
- node_js: lts/carbon
env: DEMO=demo-node-8
- node_js: lts/boron # Minimum required
env: DEMO=demo-node-6
install:
- npm install --loglevel http # Prevent timeouts for inactivity
before_script:
- npm run build
- npm run lint
script:
- npm test -- --coverage
- '[[ "$BUILD_DOCS" != true ]] || npm run doc' # Ensures ESDoc generation doesn't fail
- '[[ "$REPORT_COVERAGE" != true ]] || codecov'
- node "${DEMO-demo}"
- npm run demo
after_success: >
if [ "$TRAVIS_PULL_REQUEST" = "false" ] && [ "$BUILD_DOCS" = "true" ]; then
bash <(curl -s https://gist.githubusercontent.com/amercier/9d41002c79ac8e9fbd36bc1815d934b1/raw/) amercier/files-by-directory;
fi
deploy:
provider: npm
email: [email protected]
api_key: $NPM_AUTH_TOKEN
skip_cleanup: true
on:
tags: true
repo: amercier/files-by-directory # Prevents publishing on PRs
condition: $NPM_DEPLOY = true # Prevents publishing on each matrix build
cache:
directories:
- $HOME/.npm