-
Notifications
You must be signed in to change notification settings - Fork 4
/
.travis.yml
53 lines (53 loc) · 1.29 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
language: node_js
cache:
directories:
- ~/.npm
- .nyc_output
node_js:
- 12.13.0
notifications:
email: false
stages:
- test
- deploy
jobs:
include:
- stage: test
name: eslint
script: npx eslint .
- stage: test
name: commitlint
before_script: npm i -g @commitlint/travis-cli
script: commitlint-travis
- stage: test
name: tsc-compile-check
script: npx tsc -p tsconfig.json --noEmit
- stage: test
name: test
services:
- mongodb
- docker
before_script:
- sleep 15
- mongo growler --eval 'db.createUser({user:"travis",pwd:"test",roles:["readWrite"]});'
script: npm t
after_success:
- npm i -g coveralls codeclimate-test-reporter
- coveralls < coverage/lcov.info
- codeclimate-test-reporter < coverage/lcov.info
- stage: deploy
name: production
env:
- HEROKU_APP_NAME=api-growlerapp
- HEROKU_APP_TYPE=web
script: npx semantic-release
skip_cleanup: true
if: branch = master
- stage: deploy
name: testing
env:
- HEROKU_APP_NAME=api-growlerapp-dev
- HEROKU_APP_TYPE=web
script: bash .travis/heroku.container-release-publish.sh
skip_cleanup: true
if: branch != master