forked from latticexyz/mud
-
Notifications
You must be signed in to change notification settings - Fork 0
55 lines (44 loc) · 1.25 KB
/
examples.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
name: Examples
on:
push:
branches:
- main
paths-ignore:
- "docs/**"
pull_request:
paths-ignore:
- "docs/**"
env:
# Fix OOM errors with sourcemaps in phaser client
# https://github.com/latticexyz/mud/issues/1019
NODE_OPTIONS: --max-old-space-size=8192
jobs:
main:
name: Build/test examples
runs-on: ubuntu-latest
strategy:
matrix:
example: [minimal]
steps:
- name: Checkout
uses: actions/checkout@v3
with:
submodules: recursive
- name: Setup
uses: ./.github/actions/setup
- name: Build
uses: ./.github/actions/build
- name: Install example dependencies
working-directory: ./examples/${{ matrix.example }}
run: pnpm install
- name: Clean example
working-directory: ./examples/${{ matrix.example }}
run: pnpm run clean
- name: Build example
working-directory: ./examples/${{ matrix.example }}
run: pnpm run build
- name: Outdated files, run `pnpm run build` in `examples/${{ matrix.example }}` and commit them
uses: ./.github/actions/require-empty-diff
- name: Run tests
working-directory: ./examples/${{ matrix.example }}
run: pnpm run test