Skip to content

Commit 5ecd142

Browse files
committed
feat: Add build gh action
1 parent dece0ec commit 5ecd142

File tree

1 file changed

+48
-0
lines changed

1 file changed

+48
-0
lines changed

.github/workflows/build.yml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: 'Build & Test'
2+
on:
3+
push:
4+
branches:
5+
- master
6+
- release/**
7+
pull_request:
8+
9+
jobs:
10+
job_1:
11+
name: Build
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v2
15+
- uses: actions/setup-node@v1
16+
- uses: actions/cache@v2
17+
with:
18+
path: |
19+
node_modules
20+
*/*/node_modules
21+
key: ${{ runner.os }}-${{ hashFiles('**/yarn.lock') }}
22+
- name: Install
23+
run: yarn install
24+
- name: Build
25+
run: yarn build
26+
- name: Archive production artifacts
27+
uses: actions/upload-artifact@v1
28+
with:
29+
name: build
30+
path: |
31+
${{ github.workspace }}/packages/**/dist
32+
${{ github.workspace }}/packages/**/esm
33+
34+
job_2:
35+
name: Lint
36+
runs-on: ubuntu-latest
37+
steps:
38+
- uses: actions/checkout@v2
39+
- uses: actions/setup-node@v1
40+
- uses: actions/cache@v2
41+
with:
42+
path: |
43+
node_modules
44+
*/*/node_modules
45+
key: ${{ runner.os }}-${{ hashFiles('**/yarn.lock') }}
46+
- run: yarn install
47+
- name: Run Linter
48+
run: yarn lint

0 commit comments

Comments
 (0)