generated from donmccurdy/typescript-library-template
-
-
Notifications
You must be signed in to change notification settings - Fork 6
31 lines (28 loc) · 843 Bytes
/
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
name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
build:
runs-on: macos-latest
strategy:
matrix:
node-version: [v18, v20]
env:
CI: true
LINT: ${{ matrix.node-version == 'v18' && true || false }}
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- run: corepack enable
- run: yarn install
- run: yarn dist
- run: yarn test:node
- run: yarn test:browser
- run: yarn lint
if: ${{ env.LINT == 'true' }}