36 lines
971 B
YAML
36 lines
971 B
YAML
|
name: build
|
||
|
|
||
|
on:
|
||
|
push:
|
||
|
branches: [ main ]
|
||
|
pull_request:
|
||
|
branches: [ main ]
|
||
|
|
||
|
jobs:
|
||
|
build:
|
||
|
runs-on: ubuntu-latest
|
||
|
strategy:
|
||
|
matrix:
|
||
|
node-version: [14.x]
|
||
|
emsdk-version: [3.1.21]
|
||
|
steps:
|
||
|
- uses: actions/checkout@v3
|
||
|
- name: build emulators
|
||
|
uses: actions/setup-node@v3
|
||
|
with:
|
||
|
node-version: ${{ matrix.node-version }}
|
||
|
cache: 'npm'
|
||
|
- run: npm install -g yarn
|
||
|
- run: yarn
|
||
|
- run: yarn run eslint src --ext ts,tsx --max-warnings 0
|
||
|
- run: yarn run eslint test --ext ts,tsx --max-warnings 0
|
||
|
- run: yarn run tsc --noEmit
|
||
|
- run: git clone https://github.com/emscripten-core/emsdk.git
|
||
|
- run: cd emsdk && ./emsdk install ${{ matrix.emsdk-version }} && ./emsdk activate ${{ matrix.emsdk-version }} && cd ..
|
||
|
- run: source ./emsdk/emsdk_env.sh && yarn run gulp
|
||
|
- name: upload
|
||
|
uses: actions/upload-artifact@v3.0.0
|
||
|
with:
|
||
|
name: 'dist'
|
||
|
path: 'dist'
|