forked from jeanfortheweb/typeorm-fixture-builder
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
46 lines (41 loc) · 1.33 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
if: tag IS blank
language: node_js
node_js:
- 'lts/*'
cache:
yarn: true
before_install:
- export PATH=$HOME/.yarn/bin:$PATH
- curl -o- -L https://yarnpkg.com/install.sh | bash
install:
- git config --global user.email $GITHUB_EMAIL
- git config --global user.name $GITHUB_USER
- git remote set-url origin "https://[email protected]/$TRAVIS_REPO_SLUG.git"
- yarn
jobs:
include:
- stage: test
if: tag IS blank and branch != next and type = pull_request
before_script:
- curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
- chmod +x ./cc-test-reporter
- ./cc-test-reporter before-build
script:
- yarn jest --coverage
after_script:
- ./cc-test-reporter after-build --exit-code $TRAVIS_TEST_RESULT
- ./cc-test-reporter format-coverage -t lcov ./coverage/lcov.info
- ./cc-test-reporter upload-coverage
- stage: publish
if: tag IS blank AND branch = next AND type != pull_request
before_script:
- npm config set //registry.npmjs.org/:_authToken $NPM_TOKEN
- git checkout next
- git reset --hard
- git pull
script:
- yarn compile:cjs
- yarn compile:esm
- yarn semantic-release
after_script:
- git push