-
Notifications
You must be signed in to change notification settings - Fork 1
90 lines (73 loc) · 3.05 KB
/
build_demos.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
88
89
90
name: Build Lobster WASM demos
on:
push:
branches:
- main
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Update and install OpenGL
run: |
sudo apt-get -y update
sudo apt-get -y install libglu1-mesa-dev freeglut3-dev mesa-common-dev
- name: Set up Python
uses: actions/setup-python@v3
- name: Clone and activate Emscripten
run: |
git clone https://github.com/emscripten-core/emsdk.git
cd emsdk
./emsdk install latest
./emsdk activate latest
- name: Clone and build Lobster
run: |
git clone https://github.com/aardappel/lobster.git
cd lobster/dev
cmake -DCMAKE_BUILD_TYPE=Release
make -j8
- name: Build cube
run: |
source ./emsdk/emsdk_env.sh
python3 build.py --entry ./demos/cube/main.lobster --out-dir ./demos/cube --lobster ./lobster
- name: Build lobstercraft
run: |
source ./emsdk/emsdk_env.sh
python3 build.py --entry ./demos/lobstercraft/main.lobster --out-dir ./demos/lobstercraft --lobster ./lobster
- name: Build pendulum
run: |
source ./emsdk/emsdk_env.sh
python3 build.py --entry ./demos/pendulum/main.lobster --out-dir ./demos/pendulum --lobster ./lobster
- name: Build physics_boxes
run: |
source ./emsdk/emsdk_env.sh
python3 build.py --entry ./demos/physics_boxes/main.lobster --out-dir ./demos/physics_boxes --lobster ./lobster
- name: Build physics_water
run: |
source ./emsdk/emsdk_env.sh
python3 build.py --entry ./demos/physics_water/main.lobster --out-dir ./demos/physics_water --lobster ./lobster
- name: Build pythtree
run: |
source ./emsdk/emsdk_env.sh
python3 build.py --entry ./demos/pythtree/main.lobster --out-dir ./demos/pythtree --lobster ./lobster
- name: Setup Pages
id: pages
uses: actions/configure-pages@v3
- name: Build with Jekyll
uses: actions/jekyll-build-pages@v1
with:
source: ./
destination: ./_site
- name: Upload artifact
uses: actions/upload-pages-artifact@v2
deploy:
environment:
name: github-pages
url: ${{steps.deployment.outputs.page_url}}
runs-on: ubuntu-latest
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2