@@ -4,10 +4,10 @@ name: build
4
4
5
5
on :
6
6
workflow_dispatch :
7
- push :
7
+ # push:
8
+ # branches: [ main ]
9
+ # pull_request:
8
10
# branches: [ main ]
9
- pull_request :
10
- branches : [ main ]
11
11
12
12
jobs :
13
13
semver :
54
54
echo "MACOS_MAJORMINORPATCH=${GitVersion_MajorMinorPatch}" >> "$GITHUB_OUTPUT"
55
55
fi
56
56
57
- package-linux :
57
+ package-linux-x86_64 :
58
58
needs : [semver]
59
59
runs-on : ubuntu-latest
60
60
@@ -64,34 +64,18 @@ jobs:
64
64
with :
65
65
fetch-depth : 0
66
66
67
- - name : setup pyenv
68
- run : |
69
- sudo apt-get install python3-tk python3-venv python3-pip
70
- venv="$HOME/python3/pyinstaller"
71
- rm -Rf "$venv" # uncomment to make fresh venv.
72
- python3 -m venv "$venv"
73
- source "${venv}"/bin/activate
74
- pip install pyinstaller
75
- pip install twisted
76
-
77
- - name : Build using pyinstaller
67
+ - name : make installable tarball
78
68
run : |
79
- venv="$HOME/python3/pyinstaller"
80
- source "${venv}"/bin/activate
81
- pyinstaller \
82
- --onefile \
83
- --add-binary "oojsc.xbm:." \
84
- --add-binary "OoJSC.ico:." \
85
- DebugConsole.py
69
+ cd builder
70
+ cd Linux
71
+ ./make.sh debdeps
72
+ ./make.sh onefile Oolite-Debug-Console-${{ needs.semver.outputs.GITVERSION_SEMVER }}-linux-x86_64-installable /tmp
86
73
87
- - name : create archive
88
- run : |
89
- tar cvfz Oolite-Debug-Console-${{ needs.semver.outputs.GITVERSION_SEMVER }}-linux.tgz dist/
90
-
91
74
- uses : actions/upload-artifact@v4
92
75
with :
93
- name : Oolite-Debug-Console-Ubuntu
94
- path : ./Oolite-Debug-Console-${{ needs.semver.outputs.GITVERSION_SEMVER }}-linux.tgz
76
+ name : Oolite-Debug-Console-Linux-x86_64-Installable
77
+ path : /tmp/Oolite-Debug-Console-${{ needs.semver.outputs.GITVERSION_SEMVER }}-linux-x86_64-installable-onefile.tgz
78
+
95
79
96
80
package-windows :
97
81
needs : [semver]
@@ -105,9 +89,12 @@ jobs:
105
89
- name : Install pyinstaller
106
90
run : |
107
91
pip install -U pyinstaller
92
+ pip install -U click
108
93
pip install -U twisted
109
94
pip install -U pywin32
110
95
96
+ # Flibble. Wonder if this is actually used now? pip install -U pywin32
97
+
111
98
# in Windows PowerShell the backtick indicates a multiline command
112
99
# see https://stackoverflow.com/questions/3235850/how-to-enter-a-multi-line-command
113
100
- name : Build using pyinstaller
@@ -118,10 +105,10 @@ jobs:
118
105
--log-level=WARN `
119
106
--onefile `
120
107
--name OoDebugConsole `
121
- --add-binary "OoJSC.ico:." `
122
- --add-binary "oojsc.xbm:." `
108
+ --add-binary "images\ OoJSC.ico:." `
109
+ --add-binary "images\ oojsc.xbm:." `
123
110
--noconsole `
124
- --icon=OoJSC.ico `
111
+ --icon=images\ OoJSC.ico `
125
112
DebugConsole.py
126
113
127
114
# --version-file=OoDebug_version_info.txt `
@@ -141,7 +128,7 @@ jobs:
141
128
name : Oolite-Debug-Console-Windows
142
129
path : Oolite-Debug-Console-${{ needs.semver.outputs.GITVERSION_SEMVER }}-win.zip
143
130
144
- package-macos :
131
+ package-macos-arm64 :
145
132
needs : [semver]
146
133
runs-on : macos-latest
147
134
@@ -151,29 +138,19 @@ jobs:
151
138
with :
152
139
fetch-depth : 0
153
140
154
- - name : Install pyinstaller
155
- run : |
156
- pip install -U pyinstaller
157
-
158
- - name : Build using pyinstaller
159
- run : |
160
- pyinstaller \
161
- --onefile \
162
- --add-binary "oojsc.xbm:." \
163
- --add-binary "OoJSC.ico:." \
164
- DebugConsole.py
165
-
166
- - name : create archive
141
+ - name : make installable tarball
167
142
run : |
168
- tar cvfz Oolite-Debug-Console-${{ needs.semver.outputs.GITVERSION_SEMVER }}-macos.tgz dist/
143
+ cd builder
144
+ cd MacOS
145
+ ./make.sh app Oolite-Debug-Console-${{ needs.semver.outputs.GITVERSION_SEMVER }}-macos-arm64 /tmp
169
146
170
147
- uses : actions/upload-artifact@v4
171
148
with :
172
- name : Oolite-Debug-Console-MacOs
173
- path : ./ Oolite-Debug-Console-${{ needs.semver.outputs.GITVERSION_SEMVER }}-macos.tgz
149
+ name : Oolite-Debug-Console-MacOs-arm64
150
+ path : /tmp/ Oolite-Debug-Console-${{ needs.semver.outputs.GITVERSION_SEMVER }}-macos-arm64-app .tgz
174
151
175
152
release :
176
- needs : [semver,package-linux,package-windows,package-macos]
153
+ needs : [semver,package-linux-x86_64 ,package-windows,package-macos-arm64 ]
177
154
runs-on : ubuntu-latest
178
155
179
156
steps :
@@ -211,9 +188,9 @@ jobs:
211
188
prerelease : true
212
189
title : " Debug Console v${{ needs.semver.outputs.GITVERSION_SEMVER }}"
213
190
files : |
214
- artifacts/Oolite-Debug-Console-Ubuntu /*.tgz
191
+ artifacts/Oolite-Debug-Console-Linux-x86_64-Installable /*.tgz
215
192
artifacts/Oolite-Debug-Console-Windows/*.zip
216
- artifacts/Oolite-Debug-Console-MacOs/*.tgz
193
+ artifacts/Oolite-Debug-Console-MacOs-arm64 /*.tgz
217
194
218
195
- name : Remove old releases
219
196
if : github.ref == 'refs/heads/master'
@@ -237,7 +214,7 @@ jobs:
237
214
prerelease : false
238
215
title : " Debug Console v${{ needs.semver.outputs.GITVERSION_SEMVER }}"
239
216
files : |
240
- artifacts/Oolite-Debug-Console-Ubuntu /*.tgz
217
+ artifacts/Oolite-Debug-Console-Linux-x86_64-Installable /*.tgz
241
218
artifacts/Oolite-Debug-Console-Windows/*.zip
242
- artifacts/Oolite-Debug-Console-MacOs/*.tgz
219
+ artifacts/Oolite-Debug-Console-MacOs-arm64 /*.tgz
243
220
0 commit comments