forked from ShadowMario/FNF-PsychEngine
-
Notifications
You must be signed in to change notification settings - Fork 34
74 lines (64 loc) · 1.99 KB
/
mobile.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
name: Mobile
on:
push:
branches: mobile
workflow_dispatch:
workflow_call:
inputs:
buildFlags:
required: false
type: string
jobs:
Mobile:
runs-on: ${{matrix.os}}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-14]
steps:
- name: Checkout
uses: actions/checkout@main
with:
ref: 'mobile'
- name: Setup Haxe
uses: krdlab/setup-haxe@master
with:
haxe-version: 4.3.6
- name: Install Libraries
run: |
haxelib install hmm --quiet
haxelib run hmm install --quiet
- name: Configure Android
if: startsWith(matrix.os, 'ubuntu')
run: |
haxelib run lime config ANDROID_SDK $ANDROID_HOME
haxelib run lime config ANDROID_NDK_ROOT $ANDROID_NDK_LATEST_HOME
haxelib run lime config JAVA_HOME $JAVA_HOME_17_X64
haxelib run lime config ANDROID_SETUP true
- name: Compile (Android)
if: startsWith(matrix.os, 'ubuntu')
run: haxelib run lime build android -D ${{ inputs.buildFlags }}
- name: Compile (iOS)
if: startsWith(matrix.os, 'macos')
run: haxelib run lime build ios -nosign -D ${{ inputs.buildFlags }}
- name: Make Ipa
if: startsWith(matrix.os, 'macos')
run: |
cd export/release/ios/build/*-iphoneos
mkdir Payload
mv *.app Payload
zip -r JSEngine.ipa Payload
- name: Upload Artifact (Android)
if: startsWith(matrix.os, 'ubuntu')
uses: actions/upload-artifact@main
with:
name: androidBuild
path: export/release/android/bin/app/build/outputs/apk/release/*.apk
if-no-files-found: error
- name: Upload Artifact (iOS)
if: startsWith(matrix.os, 'macos')
uses: actions/upload-artifact@main
with:
name: iOSBuild
path: export/release/ios/build/Release-iphoneos/*.ipa
if-no-files-found: error