-
Notifications
You must be signed in to change notification settings - Fork 41
41 lines (33 loc) · 993 Bytes
/
check-dist.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
name: Check dist
on:
pull_request:
push:
branches:
- main
- 'releases/*'
jobs:
verify-build: # make sure the checked in dist/ folder matches the output of a rebuild
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }}
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version-file: .nvmrc
- name: Install npm dependencies
run: npm clean-install
- name: Rebuild the dist/ directory
run: npm run package
- name: Compare the expected and actual dist/ directories
run: script/check-diff
verify-index-js: # make sure the entrypoint js files run on a clean machine without compiling first
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.head.sha }}
- uses: ./
with:
milliseconds: 1000