-
-
Notifications
You must be signed in to change notification settings - Fork 45
148 lines (133 loc) · 3.79 KB
/
autobuild.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
name: Automatic Builds
on:
push:
branches:
- master
jobs:
build-linux:
runs-on: ubuntu-latest
steps:
- name: Install Flatpak and SDK
run: |
sudo apt update
sudo apt install flatpak flatpak-builder -y
sudo flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
sudo flatpak install flathub org.freedesktop.Platform//21.08 org.freedesktop.Sdk//21.08 -y
- name: Checkout
uses: actions/checkout@v1
- name: Compile
run: |
git config --global protocol.file.allow always
make flatpak
- name: Upload
uses: actions/upload-artifact@v2
with:
name: noods-linux
path: noods.flatpak
build-mac:
runs-on: macos-latest
steps:
- name: Install wxWidgets and PortAudio
run: brew install wxmac portaudio
- name: Checkout
uses: actions/checkout@v1
- name: Compile
run: |
make -j$(sysctl -n hw.logicalcpu)
./mac-bundle.sh --dmg
- name: Upload
uses: actions/upload-artifact@v2
with:
name: noods-mac
path: NooDS.dmg
build-windows:
runs-on: windows-latest
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Install MSYS2
uses: msys2/setup-msys2@v2
with:
msystem: MINGW64
update: true
- name: Install build tools, wxWidgets, and PortAudio
run: pacman -S mingw-w64-x86_64-{gcc,pkg-config,wxWidgets,portaudio,jbigkit} make --noconfirm
shell: msys2 {0}
- name: Compile
run: |
make -j$(nproc)
strip noods.exe
shell: msys2 {0}
working-directory: ${{ github.workspace }}
- name: Upload
uses: actions/upload-artifact@v2
with:
name: noods-windows
path: noods.exe
build-switch:
runs-on: ubuntu-latest
container: devkitpro/devkita64:latest
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Compile
run: make -f Makefile.switch -j$(nproc)
- name: Upload
uses: actions/upload-artifact@v2
with:
name: noods-switch
path: noods.nro
build-vita:
runs-on: ubuntu-latest
container: vitasdk/vitasdk:latest
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Compile
run: make -f Makefile.vita -j$(nproc)
- name: Upload
uses: actions/upload-artifact@v2
with:
name: noods-vita
path: noods.vpk
build-android:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Compile
run: |
./gradlew assembleRelease
mv build-android/outputs/apk/release/android-release-unsigned.apk noods.apk
- name: Sign
run: $ANDROID_SDK_ROOT/build-tools/29.0.3/apksigner sign --ks keystore.jks --ks-pass pass:$KEYSTORE_PASS noods.apk
env:
KEYSTORE_PASS: ${{ secrets.KEYSTORE_PASS }}
- name: Upload
uses: actions/upload-artifact@v2
with:
name: noods-android
path: noods.apk
update-release:
runs-on: ubuntu-latest
needs: [build-linux, build-mac, build-windows, build-switch, build-vita, build-android]
steps:
- name: Delete old release
uses: dev-drprasad/[email protected]
with:
delete_release: true
tag_name: release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Get artifacts
uses: actions/download-artifact@v2
- name: Package artifacts
run: for i in ./*; do zip -r -j ${i}.zip $i; done
- name: Create new release
uses: ncipollo/release-action@v1
with:
name: Rolling Release
body: These are automatically updated builds of the latest commit.
artifacts: "*.zip"
tag: release
token: ${{ secrets.GITHUB_TOKEN }}