Skip to content

Commit 64af363

Browse files
committedMay 30, 2020
chore: import Action script
1 parent 0287e40 commit 64af363

File tree

2 files changed

+50
-0
lines changed

2 files changed

+50
-0
lines changed
 

‎.github/workflows/ci.yml

+49
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
name: CI
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
test:
7+
name: Node.js v${{ matrix.nodejs }}
8+
runs-on: ubuntu-latest
9+
strategy:
10+
matrix:
11+
nodejs: [10, 12]
12+
steps:
13+
- uses: actions/checkout@master
14+
with:
15+
fetch-depth: 1
16+
17+
- uses: actions/setup-node@v1
18+
with:
19+
node-version: ${{ matrix.nodejs }}
20+
21+
- name: (env) pnpm
22+
run: curl -L https://raw.githubusercontent.com/pnpm/self-installer/master/install.js | node
23+
24+
- name: (lerna) restore
25+
uses: actions/cache@master
26+
with:
27+
path: |
28+
node_modules
29+
*/*/node_modules
30+
key: ${{ runner.os }}-${{ hashFiles('**/package.json') }}
31+
32+
- name: Install
33+
run: |
34+
pnpm install
35+
pnpm add -g nyc
36+
37+
- name: Build
38+
run: pnpm run build
39+
40+
- name: Test w/ Coverage
41+
run: nyc --include=packages pnpm test
42+
43+
- name: Report
44+
if: matrix.nodejs >= 12
45+
run: |
46+
nyc report --reporter=text-lcov > coverage.lcov
47+
bash <(curl -s https://codecov.io/bash)
48+
env:
49+
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}

‎.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
node_modules
22
.DS_Store
3+
*-lock.*
34
*.lock
45
*.log
56
dist

0 commit comments

Comments
 (0)
Please sign in to comment.