-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
47 lines (45 loc) · 1.27 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
language: node_js
node_js:
- "10"
cache:
yarn: true
directories:
- "node_modules"
jobs:
include:
- stage: Test
name: "Linting"
script: "yarn lint"
- script: yarn test:ci
name: "Produce coverage"
- stage: Build
node_js: "10"
name: "Webpack build"
script: yarn build:ci
before_deploy:
# somehow this file get's some changes...
- git checkout -- packages/webgis4u-cli/src/cli.js
- yarn before_deploy:ci
- git config --global user.email ${GH_EMAIL}
- git config --global user.name ${GH_USER}
- git remote set-url origin "https://${GH_TOKEN}@github.com/${TRAVIS_REPO_SLUG}.git" > /dev/null 2>&1
- git checkout master
- echo "//registry.npmjs.org/:_authToken=\${NPM_API_KEY}" >> $HOME/.npmrc 2> /dev/null
deploy:
provider: script
script: yarn deploy:ci
skip_cleanup: true
on:
branch: master
- stage: Docs
name: "Generate docs"
# Only generate docs for branch master
if: branch = master
script: yarn build:docs
deploy:
provider: pages
skip-cleanup: true
github-token: $GITHUB_TOKEN_GHPAGES
local-dir: packages/webgis4u/doc
on:
branch: master