-
Notifications
You must be signed in to change notification settings - Fork 5
78 lines (76 loc) · 2.25 KB
/
package.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
name: Tophat workflow
on:
push:
branches:
- main
jobs:
windows_build:
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- uses: ilammy/msvc-dev-cmd@v1
- name: Build with CMake+MSbuild
run: |
git submodule init
git submodule update --remote
./msbuild.bat
linux_build:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- name: Install packages
run: |
sudo apt update
sudo apt install -y openssh-client mesa-common-dev xorg-dev libxi-dev libxcursor-dev mingw-w64 mingw-w64-common
- name: Install SSH key
uses: shimataro/ssh-key-action@v2
with:
key: ${{ secrets.SSH_KEY }}
known_hosts: ${{ secrets.KNOWN_HOSTS }}
- name: Update submodules
run: |
git submodule init
git submodule update
- name: Build linux
run: make
- name: Build windows
run: make cross
- name: Test
run: sh cmd/checkall.sh
- name: Deploy
run: |
rsync tophat [email protected]:www/tophat-web/dl/tophat-linux
rsync tophat.exe [email protected]:www/tophat-web/dl/tophat-windows.exe
- name: On push script
run: ssh [email protected] /home/marek/on-tophat-push
- name: UmBox
uses: marekmaskarinec/umbox@master
with:
secret: ${{ secrets.UMBOX }}
emscripten_build:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- uses: mymindstorm/setup-emsdk@v14
- name: Install packages
run: |
sudo apt update
sudo apt install -y openssh-client mesa-common-dev xorg-dev libxi-dev libxcursor-dev mingw-w64
- name: Update submodules
run: |
git submodule init
git submodule update --remote
- name: Install SSH key
uses: shimataro/ssh-key-action@v2
with:
key: ${{ secrets.SSH_KEY }}
known_hosts: ${{ secrets.KNOWN_HOSTS }}
- name: Build
run: sh cmd/emscripten_build.sh
- name: Deploy
run: |
rsync th_emscripten.a [email protected]:www/tophat-web/dl/th_emscripten.a
- name: Build and deploy playground
run: |
./cmd/th_emscripten_link_playground
rsync -r ../th_wasm_data/wasm-out/* [email protected]:www/tophat-web/playground