-
Notifications
You must be signed in to change notification settings - Fork 6
/
.travis.yml
48 lines (40 loc) · 1.03 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
language: node_js
dist: xenial # 操作系统是 ubuntu xenial
node_js:
- 10.19.0
cache:
- npm
- yarn
before_install:
- npm install -g yarn
install:
- yarn install
script:
# - yarn lint
- cp .env.example .env
- yarn test
- yarn build
after_success: # after build succeeds
- yarn test:cov
notifications:
email:
recipients:
on_success: never # default: change
on_failure: always # default: always
before_deploy:
# - yarn test:e2e # run end to end tests
- mv dist synapse-extension
- rm -f synapse-extension.zip synapse-extension.asc # 保持clean的env
- zip -q -r synapse-extension.zip synapse-extension # 打包压缩
- shasum -a 256 synapse-extension.zip | tee synapse-extension.asc # 校验值并输出结果到console
deploy:
provider: releases # 操作 releases 页面
token: $GITHUB_TOKEN
file:
- synapse-extension.zip
- synapse-extension.asc
skip_cleanup: true
on: # 只有打 tag 时才运行 deploy 阶段
tags: true