-
Notifications
You must be signed in to change notification settings - Fork 14
217 lines (214 loc) · 7.08 KB
/
all_os.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
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
name: All OS
on: push
env:
CARGO_TERM_COLOR: always
jobs:
mac_universal:
defaults:
run:
working-directory: ./GDLauncher
runs-on: macos-12
timeout-minutes: 80
steps:
- uses: actions/checkout@v3
with:
path: GDLauncher
- uses: actions/setup-node@v3
with:
node-version: "22.11.0"
- uses: dtolnay/rust-toolchain@master
with:
toolchain: 1.82.0
targets: aarch64-apple-darwin, x86_64-apple-darwin
components: clippy, rustfmt
- name: Prepare
run: |
echo "" > crates/carbon_app/src/db.rs
cargo fmt --check
- run: |
npm run sudo-init
chmod -R a+x node_modules
- name: Iridium patchfix
run: node iridium_patchfix.js
- name: Prisma codegen
env:
CARGO_INCREMENTAL: 0
run: pnpm prisma:generate
- name: Build
run: pnpm build:mac-universal
env:
CARGO_INCREMENTAL: 0
BASE_API: ${{ vars.BASE_API }}
TEST_BASE_API: ${{ vars.TEST_BASE_API }}
MS_AUTH_CLIENT_ID: ${{ vars.MS_AUTH_CLIENT_ID }}
META_BASE_URL: ${{ vars.META_BASE_URL }}
USER_AGENT_PREFIX: ${{ vars.USER_AGENT_PREFIX }}
CURSEFORGE_API_KEY: "${{ vars.CURSEFORGE_API_KEY }}"
CURSEFORGE_API_BASE: ${{ vars.CURSEFORGE_API_BASE }}
- name: Lint
run: pnpm lint
- name: Clear target before tests to avoid folder getting too big
run: rm -rf target
- name: Test
env:
CARGO_INCREMENTAL: 0
BASE_API: ${{ vars.BASE_API }}
TEST_BASE_API: ${{ vars.TEST_BASE_API }}
MS_AUTH_CLIENT_ID: ${{ vars.MS_AUTH_CLIENT_ID }}
RUNTIME_PATH: ${{ vars.RUNTIME_PATH }}
META_BASE_URL: ${{ vars.META_BASE_URL }}
USER_AGENT_PREFIX: ${{ vars.USER_AGENT_PREFIX }}
CURSEFORGE_API_KEY: "${{ vars.CURSEFORGE_API_KEY }}"
CURSEFORGE_API_BASE: ${{ vars.CURSEFORGE_API_BASE }}
run: pnpm test
- name: Upload Playwright report
uses: actions/upload-artifact@v4
if: always()
with:
name: playwright-report-linux
path: ./GDLauncher/apps/desktop/playwright-report/
ubuntu_x64:
defaults:
run:
working-directory: ./GDLauncher
runs-on: ubuntu-22.04
timeout-minutes: 80
steps:
- uses: actions/checkout@v3
with:
path: GDLauncher
- uses: actions/setup-node@v3
with:
node-version: "22.11.0"
- uses: dtolnay/rust-toolchain@master
with:
toolchain: 1.82.0
targets: x86_64-unknown-linux-gnu
components: clippy, rustfmt
- name: Prepare
run: |
echo "" > crates/carbon_app/src/db.rs
cargo fmt --check
- run: |
npm run sudo-init
chmod -R a+x node_modules
- name: Iridium patchfix
run: node iridium_patchfix.js
- name: Prisma codegen
env:
CARGO_INCREMENTAL: 0
run: pnpm prisma:generate:linux-x64
- name: Build
run: pnpm build:linux-x64
env:
CARGO_INCREMENTAL: 0
BASE_API: ${{ vars.BASE_API }}
TEST_BASE_API: ${{ vars.TEST_BASE_API }}
MS_AUTH_CLIENT_ID: ${{ vars.MS_AUTH_CLIENT_ID }}
META_BASE_URL: ${{ vars.META_BASE_URL }}
USER_AGENT_PREFIX: ${{ vars.USER_AGENT_PREFIX }}
CURSEFORGE_API_KEY: "${{ vars.CURSEFORGE_API_KEY }}"
CURSEFORGE_API_BASE: ${{ vars.CURSEFORGE_API_BASE }}
- name: Lint
run: pnpm lint
- name: Clear target before tests to avoid folder getting too big
run: rm -rf target
- name: Test
env:
DISPLAY: ":1"
CARGO_INCREMENTAL: 0
BASE_API: ${{ vars.BASE_API }}
TEST_BASE_API: ${{ vars.TEST_BASE_API }}
MS_AUTH_CLIENT_ID: ${{ vars.MS_AUTH_CLIENT_ID }}
RUNTIME_PATH: ${{ vars.RUNTIME_PATH }}
META_BASE_URL: ${{ vars.META_BASE_URL }}
USER_AGENT_PREFIX: ${{ vars.USER_AGENT_PREFIX }}
CURSEFORGE_API_KEY: "${{ vars.CURSEFORGE_API_KEY }}"
CURSEFORGE_API_BASE: ${{ vars.CURSEFORGE_API_BASE }}
run: xvfb-run --auto-servernum --server-args="-screen 0 1280x960x24" -- pnpm test
- name: Upload Playwright report
if: always()
uses: actions/upload-artifact@v4
with:
name: playwright-report
path: ./GDLauncher/apps/desktop/playwright-report/
- name: Upload test results
if: always()
uses: actions/upload-artifact@v4
with:
name: playwright-report-mac
path: ./GDLauncher/apps/desktop/playwright-report/
windows_x64:
defaults:
run:
working-directory: ./GDLauncher
runs-on: windows-2022
timeout-minutes: 80
steps:
- uses: actions/checkout@v3
with:
path: GDLauncher
- uses: actions/setup-node@v3
with:
node-version: "22.11.0"
- uses: dtolnay/rust-toolchain@master
with:
toolchain: 1.82.0
targets: x86_64-pc-windows-msvc
components: clippy, rustfmt
- name: Prepare
shell: bash
run: |
echo "" > crates/carbon_app/src/db.rs
cargo fmt --check
- name: init
shell: bash
run: npm run init
- name: Iridium patchfix
shell: bash
run: node iridium_patchfix.js
- name: Prisma codegen
shell: bash
env:
CARGO_INCREMENTAL: 0
CARGO_NET_GIT_FETCH_WITH_CLI: true
run: pnpm prisma:generate:win-x64
- name: Build
shell: bash
run: pnpm build:win-x64
env:
CARGO_INCREMENTAL: 0
BASE_API: ${{ vars.BASE_API }}
TEST_BASE_API: ${{ vars.TEST_BASE_API }}
MS_AUTH_CLIENT_ID: ${{ vars.MS_AUTH_CLIENT_ID }}
META_BASE_URL: ${{ vars.META_BASE_URL }}
USER_AGENT_PREFIX: ${{ vars.USER_AGENT_PREFIX }}
CURSEFORGE_API_KEY: "${{ vars.CURSEFORGE_API_KEY }}"
CURSEFORGE_API_BASE: ${{ vars.CURSEFORGE_API_BASE }}
CARGO_NET_GIT_FETCH_WITH_CLI: true
- name: Lint
shell: bash
run: pnpm lint
- name: Clear target before tests to avoid folder getting too big
shell: bash
run: rm -rf target
- name: Test
shell: bash
env:
CARGO_INCREMENTAL: 0
BASE_API: ${{ vars.BASE_API }}
TEST_BASE_API: ${{ vars.TEST_BASE_API }}
MS_AUTH_CLIENT_ID: ${{ vars.MS_AUTH_CLIENT_ID }}
RUNTIME_PATH: ${{ vars.RUNTIME_PATH }}
META_BASE_URL: ${{ vars.META_BASE_URL }}
USER_AGENT_PREFIX: ${{ vars.USER_AGENT_PREFIX }}
CURSEFORGE_API_KEY: "${{ vars.CURSEFORGE_API_KEY }}"
CURSEFORGE_API_BASE: ${{ vars.CURSEFORGE_API_BASE }}
CARGO_NET_GIT_FETCH_WITH_CLI: true
run: pnpm test
- name: Upload Playwright report
uses: actions/upload-artifact@v4
if: always()
with:
name: playwright-report-win
path: ./GDLauncher/apps/desktop/playwright-report/