forked from InsightSoftwareConsortium/ITK-Wasm
-
Notifications
You must be signed in to change notification settings - Fork 0
87 lines (69 loc) · 2.17 KB
/
javascript-typescript.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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
name: Node.js Tests
on:
push:
branches:
- main
pull_request:
branches:
- main
defaults:
run:
shell: bash -leo pipefail {0} {0}
env:
OCI_EXE: docker
jobs:
itkwasm-node-js:
runs-on: ubuntu-22.04
strategy:
max-parallel: 3
matrix:
package: [compress-stringify, compare-images, dicom, mesh-io, image-io, transform-io, downsample]
steps:
- uses: actions/checkout@v4
- name: Free Disk Space (Ubuntu)
uses: jlumbroso/free-disk-space@main
- name: Pull latest Docker images
run: |
./src/docker/pull.sh --no-debug
- uses: actions/setup-node@v4
with:
node-version: '20'
- name: Install
uses: pnpm/action-setup@v4
with:
run_install: true
- name: Build itk-wasm
run: |
pnpm run --aggregate-output --filter itk-wasm build
- name: Build @itk-wasm/demo-app
run: |
pnpm run --aggregate-output --filter '@itk-wasm/demo-app' build
- name: Build build:gen:typescript
run: |
pnpm run --aggregate-output --filter "@itk-wasm/${{ matrix.package }}-build..." build:gen:typescript
- name: Build typescript
run: |
pnpm install
# Build the generated TypeScript package
pnpm run --aggregate-output --filter "@itk-wasm/${{ matrix.package }}..." build:tsc
pnpm run --aggregate-output --filter "@itk-wasm/${{ matrix.package }}" build
- name: Download test data
run: |
pnpm run --aggregate-output --filter "@itk-wasm/${{ matrix.package }}-build" test:data:download
- name: Lint tests
run: |
pnpm run test:lint
- name: Node tests
run: |
pnpm run --aggregate-output --filter "@itk-wasm/${{ matrix.package }}" test:node
- name: itk-wasm Node tests
run: |
pnpm run --aggregate-output --filter "itk-wasm" test:node
- name: Publish task
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
run: |
git config --global user.name "GitHub Actions"
git config --global user.email "[email protected]"
# todo: use changeset / pnpm publish