-
-
Notifications
You must be signed in to change notification settings - Fork 130
/
.travis.yml
90 lines (81 loc) · 2.23 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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
language: node_js
node_js: # will use latest stable node
- 'stable'
#addons:
# chrome: stable
cache: # global caching
directories:
# - node_modules
- $HOME/.npm
branches:
except:
- /^v\d+\.\d+\.\d+$/
notifications:
email: # only receive email when the build status changes (someone broke the build!)
on_failure: change
on_success: change
env:
- NODE_ENV=mock
stages:
# - lint
# - test
# - build
- name: release
if: branch = master AND type IN (push)
- name: deploy
if: branch = master AND type != pull_request
- name: docs
if: branch = master AND type != pull_request
jobs:
include:
# - stage: lint
# script: npm run lint
# - stage: test # unit test
# script:
# - npm run test:ci
## - "npm testcafe 'path:`/usr/bin/google-chrome-stable` --headless --disable-gpu --remote-debugging-port=9222 --remote-debugging-address=0.0.0.0' apps/webapp-e2e/**/*.e2e-spec.ts --app 'npm run start' --skip-js-errors --app-init-delay 4000"
# - stage: test # e2e test
# script:
# - npm run e2e:ci
# - stage: build
# before_script: npm run prebuild
# script:
# - npm run build:mock
- stage: release # semantic release - create changelog
script: skip
deploy:
provider: script
script: npm run release
skip-cleanup: true
- stage: release # github release
if: branch = master AND tag IS present
install: skip
script: npm run build:mock
before_deploy:
- tar czvf webapp.tar.gz -C dist/apps/webapp .
deploy:
- provider: releases
api_key: $GITHUB_TOKEN
file: './webapp.tar.gz'
skip_cleanup: true
- stage: deploy
install: skip
script: npm run build:mock
deploy:
provider: pages
github_token: $GITHUB_TOKEN
target-branch: gh-pages
local_dir: dist/apps/webapp
skip-cleanup: true
keep-history: true
- stage: docs
if: branch = master AND tag IS present
install: skip
script: npm run doc:build
deploy:
provider: pages
github_token: $GITHUB_TOKEN
target-branch: docs
local_dir: docs
skip-cleanup: true
keep-history: true