Skip to content

Commit c4a8ff6

Browse files
committed
ci: test coverage and split out release job
1 parent 6fb8ef6 commit c4a8ff6

File tree

1 file changed

+21
-3
lines changed

1 file changed

+21
-3
lines changed

.github/workflows/ci.yml

Lines changed: 21 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,11 @@ on:
88
branches:
99
- main
1010

11+
permissions: {}
12+
1113
jobs:
1214
ci:
1315
runs-on: ubuntu-latest
14-
permissions:
15-
id-token: write
1616
steps:
1717
- uses: actions/checkout@v3
1818
- run: corepack enable
@@ -45,10 +45,28 @@ jobs:
4545

4646
- run: pnpm dev:prepare
4747
- run: pnpm lint
48-
- run: pnpm test
48+
- run: pnpm test -- --coverage
4949
- run: pnpm build
5050
- run: pnpm test:types
5151
- run: pnpm dev:build
52+
- uses: codecov/codecov-action@v3
53+
54+
release:
55+
runs-on: ubuntu-latest
56+
needs: ci
57+
if: github.event_name == 'push' && !contains(github.event.head_commit.message, '[skip-release]')
58+
permissions:
59+
id-token: write
60+
steps:
61+
- uses: actions/checkout@v3
62+
- run: corepack enable
63+
- uses: actions/setup-node@v3
64+
with:
65+
node-version: 20
66+
cache: "pnpm"
67+
- run: pnpm install
68+
- run: pnpm dev:prepare
69+
- run: pnpm build
5270
- name: Release Edge
5371
if: |
5472
github.event_name == 'push' &&

0 commit comments

Comments
 (0)