-
Notifications
You must be signed in to change notification settings - Fork 0
54 lines (44 loc) · 1.05 KB
/
ci.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
name: CI
on: [push]
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 10
- run: npm ci
- run: npm run prettier:lint
- run: npm run schema:lint
- run: npm run events:lint
build:
runs-on: ubuntu-latest
needs: lint
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 10
- run: npm ci
- run: npm run build
env:
CI: true
- uses: actions/upload-artifact@v1
with:
name: dist
path: dist
deploy:
if: github.event_name == 'push' && github.ref == 'refs/heads/master'
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/download-artifact@v1
with:
name: dist
- run: npm ci
- shell: bash
env:
TW_CALC_API_KEY: ${{ secrets.TW_CALC_API_KEY }}
run: npm run deploy -- "$TW_CALC_API_KEY"