-
-
Notifications
You must be signed in to change notification settings - Fork 12
/
Copy path.travis.yml
66 lines (65 loc) · 1.53 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
language: node_js
cache:
directories:
- ~/.npm
notifications:
email: false
node_js:
- '11'
before_install:
- npm install -g greenkeeper-lockfile@1
install:
- npm install
before_script:
- greenkeeper-lockfile-update
script:
- npm run lint
- npm run build
after_script:
- greenkeeper-lockfile-upload
before_deploy:
- |
if [ $TRAVIS_BRANCH == "master" ] && [ ! -d release ];
then echo "Create tar file before_deployment on master branch"
mkdir release && tar --exclude='./dist/demo.html' -zcvf release/web3ready-release.tar.gz dist
fi
jobs:
include:
# Define the release stage that runs semantic-release
- stage: release
node_js: '11'
# Advanced: optionally overwrite your default `script` step to skip the tests
# script: skip
deploy:
# Deploy github release
- provider: script
skip_cleanup: true
script: npx semantic-release
on:
branches:
only:
- master
# Demo page for dev branch
- provider: pages
skip-cleanup: true
github-token: $GH_TOKEN
local-dir: dist
keep-history: false
target-branch: gh-pages
repo: web3ready/dev
on:
branches:
only:
- dev
# Demo page for Releases
- provider: pages
skip-cleanup: true
github-token: $GH_TOKEN
local-dir: dist
keep-history: false
target-branch: gh-pages
repo: web3ready/latest
on:
branches:
only:
- master