Skip to content

Commit ab72301

Browse files
committed
Update CI with Mac build
Linux and Mac have separate binaries now as we've noticed that InControl differs between them, this should hopefully fix cross-platform controller support for good.
1 parent b1c3175 commit ab72301

File tree

1 file changed

+34
-6
lines changed

1 file changed

+34
-6
lines changed

.github/workflows/build.yaml

Lines changed: 34 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929
name: ModdingApiWin
3030
path: ./OutputFinal/
3131

32-
build-unix:
32+
build-linux:
3333
runs-on: ubuntu-latest
3434
steps:
3535
- uses: actions/checkout@v2
@@ -49,14 +49,40 @@ jobs:
4949
- name: Build Assembly-CSharp
5050
run: |
5151
dotnet build Assembly-CSharp -p:SolutionDir=$PWD -p:Configuration=Release
52-
- name: Upload Unix-like Binary
52+
- name: Upload Linux Binary
5353
uses: actions/upload-artifact@v2
5454
with:
55-
name: ModdingApiUnix
55+
name: ModdingApiLinux
56+
path: ./OutputFinal/
57+
58+
build-mac:
59+
runs-on: ubuntu-latest
60+
steps:
61+
- uses: actions/checkout@v2
62+
- name: Setup Vanilla
63+
run: |
64+
wget https://files.catbox.moe/j8fyro.zip -O Vanilla.zip
65+
unzip Vanilla.zip -d Vanilla
66+
- name: Setup .NET
67+
uses: actions/setup-dotnet@v1
68+
- name: Setup ms-build
69+
run: sudo apt-get install -y nuget mono-devel mono-xbuild
70+
- name: Restore dependencies
71+
run: dotnet restore
72+
- name: Build PrePatcher
73+
run: |
74+
dotnet build PrePatcher -o PrePatcher/Output -p:Configuration=Release
75+
- name: Build Assembly-CSharp
76+
run: |
77+
dotnet build Assembly-CSharp -p:SolutionDir=$PWD -p:Configuration=Release
78+
- name: Upload Mac Binary
79+
uses: actions/upload-artifact@v2
80+
with:
81+
name: ModdingApiMac
5682
path: ./OutputFinal/
5783

5884
release:
59-
needs: [build-win, build-unix]
85+
needs: [build-win, build-linux, build-mac]
6086
runs-on: ubuntu-latest
6187
if: startsWith(github.ref, 'refs/tags')
6288
steps:
@@ -67,10 +93,12 @@ jobs:
6793
- name: Zip
6894
run: |
6995
zip -jr ModdingApiWin.zip ./artifacts/ModdingApiWin/*
70-
zip -jr ModdingApiUnix.zip ./artifacts/ModdingApiUnix/*
96+
zip -jr ModdingApiLinux.zip ./artifacts/ModdingApiLinux/*
97+
zip -jr ModdingApiMac.zip ./artifacts/ModdingApiMac/*
7198
- name: Create release if a new tag is pushed
7299
uses: softprops/action-gh-release@v1
73100
with:
74101
files: |
75102
./ModdingApiWin.zip
76-
./ModdingApiUnix.zip
103+
./ModdingApiLinux.zip
104+
./ModdingApiMac.zip

0 commit comments

Comments
 (0)