forked from goonstation/goonstation
-
Notifications
You must be signed in to change notification settings - Fork 0
202 lines (169 loc) · 7 KB
/
automaton.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
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
# Automaton, a beepsky supplement for checking runtime violations in maps
# Based on Turdis by Yogstation
name: Automaton
on:
pull_request:
branches: [master]
push:
branches:
- "master"
jobs:
runtime:
name: Runtime Checker
runs-on: ubuntu-20.04
if: "!contains(github.event.head_commit.message, 'skip ci')"
strategy:
fail-fast: false
matrix:
map: ["COGMAP", "COGMAP2", "CLARION", "DONUT3", "DONUT2", "OSHAN", "KONDARU", "NADIR", "ATLAS", "SPACE_PREFAB", "UNDERWATER_PREFAB", "FULL"]
compiletype: ["default"]
steps:
- uses: actions/checkout@v3
- name: Install Dependencies
run: |
sudo dpkg --add-architecture i386
sudo sed -i 's/azure\.//' /etc/apt/sources.list
sudo apt-get update
sudo apt install -o Acquire::Retries=3 libstdc++6:i386 libssl1.1:i386
- name: Cache BYOND
uses: actions/cache@v3
with:
path: ~/BYOND
key: ${{ runner.os }}-byond-${{ hashFiles('buildByond.conf')}}
restore-keys: ${{ runner.os }}-byond
- name: Setup BYOND
run: |
tools/ci/install_byond.sh
cd $GITHUB_WORKSPACE
printenv
echo "BYOND_SYSTEM=/home/runner/BYOND/byond" >> $GITHUB_ENV
echo "/home/runner/BYOND/byond/bin" >> $GITHUB_PATH
echo "LD_LIBRARY_PATH=/home/runner/BYOND/byond/bin:$LD_LIBRARY_PATH" >> $GITHUB_ENV
echo "MANPATH=/home/runner/BYOND/byond/man:$MANPATH" >> $GITHUB_ENV
touch +secret/__secret.dme
- name: Setup for assjam
if: "matrix.compiletype == 'ass'"
run: |
sed -i 's/BUILD_TIME_DAY 01/BUILD_TIME_DAY 13/' _std/__build.dm
- name: Setup rust-g
run: |
tools/ci/install_rust_g.sh
- name: Compile map
if: "matrix.map != 'SPACE_PREFAB' && matrix.map != 'UNDERWATER_PREFAB' && matrix.map != 'FULL'"
run: |
tools/ci/dm.sh -DCIBUILD -DMAP_OVERRIDE_${{ matrix.map}} -DRUNTIME_CHECKING -DIM_REALLY_IN_A_FUCKING_HURRY_HERE goonstation.dme
- name: Compile space prefabs
if: "matrix.map == 'SPACE_PREFAB'"
run: |
tools/ci/dm.sh -DCIBUILD -DSPACE_PREFAB_RUNTIME_CHECKING -DIM_REALLY_IN_A_FUCKING_HURRY_HERE goonstation.dme
- name: Compile underwater prefabs
if: "matrix.map == 'UNDERWATER_PREFAB'"
run: |
tools/ci/dm.sh -DCIBUILD -DUNDERWATER_PREFAB_RUNTIME_CHECKING -DIM_REALLY_IN_A_FUCKING_HURRY_HERE goonstation.dme
- name: Compile with full pre-round setup
if: "matrix.map == 'FULL'"
run: |
tools/ci/dm.sh -DCIBUILD -DRUNTIME_CHECKING goonstation.dme
- name: Run map and check for runtime errors
run: |
tools/ci/run_server.sh
runtime_full:
name: "Runtime Checker with Secret Submodule"
runs-on: ubuntu-20.04
if: |
((github.event_name == 'push' && github.repository == 'goonstation/goonstation') || (github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == 'goonstation/goonstation')) && !contains(github.event.head_commit.message, 'skip ci')
strategy:
fail-fast: false
matrix:
map: ["COGMAP", "COGMAP2", "CLARION", "DESTINY", "DONUT3", "DONUT2", "OSHAN", "KONDARU", "NADIR", "ATLAS", "SPACE_PREFAB", "UNDERWATER_PREFAB", "FULL"]
compiletype: ["default"]
steps:
- uses: actions/checkout@v3
with:
submodules: true
token: '${{ secrets.ROBUDDYBOT_PAT }}'
- name: Install Dependencies
run: |
sudo dpkg --add-architecture i386
sudo sed -i 's/azure\.//' /etc/apt/sources.list
sudo apt-get update
sudo apt install -o Acquire::Retries=3 libstdc++6:i386 libssl1.1:i386
- name: Cache BYOND
uses: actions/cache@v3
with:
path: ~/BYOND
key: ${{ runner.os }}-byond-${{ hashFiles('buildByond.conf')}}
restore-keys: ${{ runner.os }}-byond
- name: Setup BYOND
run: |
tools/ci/install_byond.sh
cd $GITHUB_WORKSPACE
printenv
echo "BYOND_SYSTEM=/home/runner/BYOND/byond" >> $GITHUB_ENV
echo "/home/runner/BYOND/byond/bin" >> $GITHUB_PATH
echo "LD_LIBRARY_PATH=/home/runner/BYOND/byond/bin:$LD_LIBRARY_PATH" >> $GITHUB_ENV
echo "MANPATH=/home/runner/BYOND/byond/man:$MANPATH" >> $GITHUB_ENV
touch +secret/__secret.dme
- name: Setup for assjam
if: "matrix.compiletype == 'ass'"
run: |
sed -i 's/BUILD_TIME_DAY 01/BUILD_TIME_DAY 13/' _std/__build.dm
- name: Setup rust-g
run: |
tools/ci/install_rust_g.sh
- name: Compile map
if: "matrix.map != 'SPACE_PREFAB' && matrix.map != 'UNDERWATER_PREFAB' && matrix.map != 'FULL'"
run: |
tools/ci/dm.sh -DCIBUILD -DMAP_OVERRIDE_${{ matrix.map}} -DRUNTIME_CHECKING -DIM_REALLY_IN_A_FUCKING_HURRY_HERE goonstation.dme
- name: Compile space prefabs
if: "matrix.map == 'SPACE_PREFAB'"
run: |
tools/ci/dm.sh -DCIBUILD -DSPACE_PREFAB_RUNTIME_CHECKING -DIM_REALLY_IN_A_FUCKING_HURRY_HERE goonstation.dme
- name: Compile underwater prefabs
if: "matrix.map == 'UNDERWATER_PREFAB'"
run: |
tools/ci/dm.sh -DCIBUILD -DUNDERWATER_PREFAB_RUNTIME_CHECKING -DIM_REALLY_IN_A_FUCKING_HURRY_HERE goonstation.dme
- name: Compile with full pre-round setup
if: "matrix.map == 'FULL'"
run: |
tools/ci/dm.sh -DCIBUILD -DRUNTIME_CHECKING goonstation.dme
- name: Run map and check for runtime errors
run: |
tools/ci/run_server.sh
unit_test:
name: Unit Tests
runs-on: ubuntu-20.04
if: "!contains(github.event.head_commit.message, 'skip ci')"
steps:
- uses: actions/checkout@v3
- name: Install Dependencies
run: |
sudo dpkg --add-architecture i386
sudo sed -i 's/azure\.//' /etc/apt/sources.list
sudo apt-get update
sudo apt install -o Acquire::Retries=3 libstdc++6:i386 libssl1.1:i386
- name: Cache BYOND
uses: actions/cache@v3
with:
path: ~/BYOND
key: ${{ runner.os }}-byond-${{ hashFiles('buildByond.conf')}}
restore-keys: ${{ runner.os }}-byond
- name: Setup BYOND
run: |
tools/ci/install_byond.sh
cd $GITHUB_WORKSPACE
printenv
echo "BYOND_SYSTEM=/home/runner/BYOND/byond" >> $GITHUB_ENV
echo "/home/runner/BYOND/byond/bin" >> $GITHUB_PATH
echo "LD_LIBRARY_PATH=/home/runner/BYOND/byond/bin:$LD_LIBRARY_PATH" >> $GITHUB_ENV
echo "MANPATH=/home/runner/BYOND/byond/man:$MANPATH" >> $GITHUB_ENV
touch +secret/__secret.dme
- name: Setup rust-g
run: |
tools/ci/install_rust_g.sh
- name: Build Unit Tests
run: |
tools/ci/dm.sh -DCIBUILD -DUNIT_TESTS -DUNIT_TESTS_RUN_TILL_COMPLETION goonstation.dme
- name: Run Unit Tests
run: |
tools/ci/run_server.sh