-
Notifications
You must be signed in to change notification settings - Fork 13
72 lines (64 loc) · 1.77 KB
/
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
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
name: CI
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
ci-ubuntu:
strategy:
matrix:
version: [18]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: ${{ matrix.version }}
- run: |
git clone https://github.com/emscripten-core/emsdk.git /tmp/emsdk
/tmp/emsdk/emsdk install latest
/tmp/emsdk/emsdk activate latest
name: Setup emcc
- run: npm ci
- run: |
export PATH=$PATH:/tmp/emsdk:/tmp/emsdk/upstream/emscripten
npm run build-wasm
working-directory: l10n-dev
name: Compile wasm binaries
- uses: actions/upload-artifact@v3
name: upload tree-sitter-tsx.wasm
with:
name: tree-sitter-tsx.wasm
path: l10n-dev/src/ast/tree-sitter-tsx.wasm
- uses: actions/upload-artifact@v3
name: upload tree-sitter-typescript.wasm
with:
name: tree-sitter-typescript.wasm
path: l10n-dev/src/ast/tree-sitter-typescript.wasm
- run: npm test
ci-windows:
needs: ci-ubuntu
strategy:
matrix:
version: [18]
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: ${{ matrix.version }}
- run: npm ci
- uses: actions/download-artifact@v3
name: download tree-sitter-tsx.wasm
with:
name: tree-sitter-tsx.wasm
path: l10n-dev/src/ast
- uses: actions/download-artifact@v3
name: download tree-sitter-typescript.wasm
with:
name: tree-sitter-typescript.wasm
path: l10n-dev/src/ast
- run: npm test