-
Notifications
You must be signed in to change notification settings - Fork 16
671 lines (591 loc) · 25.8 KB
/
release.yaml
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
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
name: create-github-release
on:
push:
branches: [ main ]
env:
# Used as the name when uploading or downloading the artifact for passing
# configuration data from the Setup job to those dependent on it.
CONFIG_ARTIFACT: release-config
# Used as the path for the file with the configuration data passed from
# the Setup job to those dependent on it.
CONFIG_ARTIFACT_PATH: release-config.txt
# Used as the name when uploading or downloading the artifact with the
# converted document files.
DOC_ARTIFACT: release-docs
# Used as the path for the file with the converted document files.
DOC_ARTIFACT_PATH: release-docs.tar
# Used as the name when uploading or downloading the artifact for passing
# the name of the source archive.
SRC_ARTIFACT: release-src
# Used as the path for the file with the name of the source archive in it.
SRC_ARTIFACT_PATH: release-src.txt
# Used as the name when uploading or downloading the artifact holding
# the source archive.
SRC_ARCHIVE_ARTIFACT: release-src-archive
# Used as the name when uploading or downloading the artifact for passing
# the name of the Windows archive.
WIN_ARTIFACT: release-win
# Used as the path for the file with the name of the Windows archive in it.
WIN_ARTIFACT_PATH: release-win.txt
# Used as the name when uploading or downloading the artifact holding
# the Windows archive.
WIN_ARCHIVE_ARTIFACT: release-win-archive
# Used as the name when uploading or downloading the artifact for passing
# the name of the Mac archive.
MAC_ARTIFACT: release-mac
# Used as the path for the file with the name of the Mac archive in it.
MAC_ARTIFACT_PATH: release-mac.txt
# Used as the name when uploading or downloading the artifact holding
# the Mac archive.
MAC_ARCHIVE_ARTIFACT: release-mac-archive
# Used as the name when uploading or downloading the artifact for passing
# the name of the Nintendo NDS archive.
NIN_DS_ARTIFACT: release-ds
# Used as the path for the file with the name of the Nintendo NDS archive
# in it.
NIN_DS_ARTIFACT_PATH: release-ds.txt
# Used as the name when uploading or downloading the artifact holding
# the Nintendo DS archive.
NIN_DS_ARCHIVE_ARTIFACT: release-ds-archive
# Used as the name when uploading or downloading the artifact for passing
# the name of the Nintendo 3DS archive.
NIN_3DS_ARTIFACT: release-3ds
# Used as the path for the file with the name of the Nintendo 3DS archive
# in it.
NIN_3DS_ARTIFACT_PATH: release-3ds.txt
# Used as the name when uploading or downloading the artifact holding
# the Nintendo 3DS archive.
NIN_3DS_ARCHIVE_ARTIFACT: release-3ds-archive
jobs:
setup:
name: Setup
runs-on: ubuntu-latest
steps:
# Need commit history and tags for scripts/version.sh to work as expected
# so use 0 for fetch-depth.
- name: Clone Project
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Extract Names from Makefile
id: get_names
run: |
name=`sed -E -n -e 's/^[[:blank:]]*NAME[[:blank:]]+=[[:blank:]]+//p' src/Makefile.src | tr ' #' '\t\t' | tail -1 | cut -f 1`
echo "name=$name" >> $GITHUB_OUTPUT
prog=`sed -E -n -e 's/^[[:blank:]]*PROGNAME[[:blank:]]+=[[:blank:]]+//p' src/Makefile.src | tr ' #' '\t\t' | tail -1 | cut -f 1`
echo "prog=$prog" >> $GITHUB_OUTPUT
- name: Set Release Version
id: get_release_vars
run: |
version=`scripts/version.sh`
echo "version=$version" >> $GITHUB_OUTPUT
prerelease=`echo $version | awk '/^[[:digit:]]+\.[[:digit:]]+\.[[:digit:]]+$/ { print "false" ; exit 0 } ; { print "true"; exit 0 } ;'`
echo "prerelease=$prerelease" >> $GITHUB_OUTPUT
# Mark anything that isn't a prerelease as a draft.
draft=true
if test x$prerelease = xtrue ; then
draft=false
fi
echo "draft=$draft" >> $GITHUB_OUTPUT
# The quoting here may be too simple-minded: what if there are single
# quotes in the steps.*.outputs.* stuff.
- name: Create Artifact with Configuration Details
run: |
echo name= '${{ steps.get_names.outputs.name }}' > $CONFIG_ARTIFACT_PATH
echo prog= '${{ steps.get_names.outputs.prog }}' >> $CONFIG_ARTIFACT_PATH
echo version= '${{ steps.get_release_vars.outputs.version }}' >> $CONFIG_ARTIFACT_PATH
echo prerelease= '${{ steps.get_release_vars.outputs.prerelease }}' >> $CONFIG_ARTIFACT_PATH
echo draft= '${{ steps.get_release_vars.outputs.draft }}' >> $CONFIG_ARTIFACT_PATH
- name: Upload Artifact for Use by Dependent Steps
uses: actions/upload-artifact@v4
with:
name: ${{ env.CONFIG_ARTIFACT }}
path: ${{ env.CONFIG_ARTIFACT_PATH }}
retention-days: 1
docconvert:
name: Document Conversion
runs-on: ubuntu-latest
steps:
# Need commit history and tags for scripts/version.sh to work as expected
# so use 0 for fetch-depth. Do this before installing the build
# dependencies as that step does some writing to the current directory
# and cloning the project wipes the current directory.
- name: Clone Project
uses: actions/checkout@v4
with:
fetch-depth: 0
# Need both Sphinx (Python documentation tool) and a 3rd party theme.
# Also install pip (to get theme), gcc, automake, autoconf, make
# (those four are so configuration and "make manual" work), and git
# (so scripts/version.sh works). With Python 3, use a virtual
# environment (requires at least Python 3.3) to install the 3rd party
# theme and a hacked version of sphinx-build which will use that
# environment for compatibility with "externally managed environments"
# like GitHub's runner for Ubuntu 24.04.
- name: Install Build Dependencies
id: build_dep
run: |
sudo apt-get update
sudo apt-get install autoconf automake gcc make sphinx-common git
use_python3=`python --version 2>&1 | awk "/^Python 3\\./ { print \"YES\" ; exit 0 ; } ; { print \"NO\" ; exit 0; }"`
if test X$use_python3 == XYES ; then
sudo apt-get install python3-pip
python3 -m venv .venv/doc-builder
.venv/doc-builder/bin/pip install -U sphinx
.venv/doc-builder/bin/pip install sphinx-better-theme
echo "#!${PWD}/.venv/doc-builder/bin/python" >./sphinx-build
tail -n +2 `which sphinx-build` >>./sphinx-build
chmod a+x ./sphinx-build
else
sudo apt-get install python-pip
pip install sphinx-better-theme
ln -s `which sphinx-build` ./sphinx-build
fi
# Use the version (perhaps just a symbolic link) of sphinx-build set up
# in the build dependencies step.
- name: Convert
run: |
./autogen.sh
./configure SPHINXBUILD="${PWD}/sphinx-build" --with-no-install --with-sphinx
make manual
- name: Archive
run: |
tar -cf ${{ env.DOC_ARTIFACT_PATH }} docs/_build/html
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: ${{ env.DOC_ARTIFACT }}
path: ${{ env.DOC_ARTIFACT_PATH }}
retention-days: 1
source:
needs: setup
name: Source Archive
runs-on: ubuntu-latest
steps:
- name: Download Artifact with Configuration Information
uses: actions/download-artifact@v4
with:
name: ${{ env.CONFIG_ARTIFACT }}
- name: Extract Configuration Information and Store in Step Outputs
id: store_config
run: |
name=`sed -E -n -e 's/name= //p' $CONFIG_ARTIFACT_PATH`
echo "name=$name" >> $GITHUB_OUTPUT
prog=`sed -E -n -e 's/prog= //p' $CONFIG_ARTIFACT_PATH`
echo "prog=$prog" >> $GITHUB_OUTPUT
version=`sed -E -n -e 's/version= //p' $CONFIG_ARTIFACT_PATH`
echo "version=$version" >> $GITHUB_OUTPUT
- name: Install Build Dependencies
run: |
sudo apt-get update
sudo apt-get install automake autoconf git make
# Need commit history and tags for scripts/version.sh to work as expected
# so use 0 for fetch-depth.
- name: Clone Project
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Create Source Archive
id: create_source_archive
run: |
./autogen.sh
./configure
archive_prefix=${{ steps.store_config.outputs.name }}-${{ steps.store_config.outputs.version }}
echo "archive_file=${archive_prefix}.tar.gz" >> $GITHUB_OUTPUT
make TAG="$archive_prefix" OUT="$archive_prefix".tar.gz dist
- name: Create Artifact with Source Archive Path
run: |
echo archive_path= '${{ steps.create_source_archive.outputs.archive_file }}' > $SRC_ARTIFACT_PATH
- name: Upload Artifact with Source Archive Path
uses: actions/upload-artifact@v4
with:
name: ${{ env.SRC_ARTIFACT }}
path: ${{ env.SRC_ARTIFACT_PATH }}
retention-days: 1
- name: Upload Source Archive as Artifact
uses: actions/upload-artifact@v4
with:
name: ${{ env.SRC_ARCHIVE_ARTIFACT }}
path: ${{ steps.create_source_archive.outputs.archive_file }}
retention-days: 1
windows:
needs: [setup, docconvert]
name: Windows
runs-on: ubuntu-22.04
steps:
- name: Download Artifact with Configuration Information
uses: actions/download-artifact@v4
with:
name: ${{ env.CONFIG_ARTIFACT }}
- name: Extract Configuration Information and Store in Step Outputs
id: store_config
run: |
name=`sed -E -n -e 's/name= //p' $CONFIG_ARTIFACT_PATH`
echo "name=$name" >> $GITHUB_OUTPUT
prog=`sed -E -n -e 's/prog= //p' $CONFIG_ARTIFACT_PATH`
echo "prog=$prog" >> $GITHUB_OUTPUT
version=`sed -E -n -e 's/version= //p' $CONFIG_ARTIFACT_PATH`
echo "version=$version" >> $GITHUB_OUTPUT
- name: Install Build Dependencies
run: |
sudo apt-get update
sudo apt-get install gcc-mingw-w64 automake autoconf git make zip
# Need commit history and tags for scripts/version.sh to work as expected
# so use 0 for fetch-depth.
- name: Clone Project
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Download Artifact with Converted Documents
uses: actions/download-artifact@v4
with:
name: ${{ env.DOC_ARTIFACT }}
- name: Extract Converted Documents
run: |
tar -xf ${{ env.DOC_ARTIFACT_PATH }}
# Override the default CFLAGS, -g -O2, to get a smaller executable (~2
# MB versus ~7 MB), all due to compiling without debugging symbols.
# Adding the option to strip symbols and relocation information, -s,
# or the option to optimize for size, -Os, didn't further reduce the
# size of the executable when using mingw 6.0.0 on Debian buster.
- name: Create Windows Archive
id: create_windows_archive
run: |
./autogen.sh
env CFLAGS="-O2" ./configure --enable-release --enable-win --build=i686-pc-linux-gnu --host=i686-w64-mingw32
make
cp src/${{ steps.store_config.outputs.prog }}.exe src/win/dll/libpng12.dll src/win/dll/zlib1.dll .
archive_prefix=${{ steps.store_config.outputs.name }}-${{ steps.store_config.outputs.version }}
echo "archive_file=${archive_prefix}-win.zip" >> $GITHUB_OUTPUT
scripts/pkg_win $archive_prefix ${archive_prefix}-win.zip
- name: Create Artifact with Windows Archive Path
run: |
echo archive_path= '${{ steps.create_windows_archive.outputs.archive_file }}' > $WIN_ARTIFACT_PATH
- name: Upload Artifact with Windows Archive Path
uses: actions/upload-artifact@v4
with:
name: ${{ env.WIN_ARTIFACT }}
path: ${{ env.WIN_ARTIFACT_PATH }}
retention-days: 1
- name: Upload Windows Archive as Artifact
uses: actions/upload-artifact@v4
with:
name: ${{ env.WIN_ARCHIVE_ARTIFACT }}
path: ${{ steps.create_windows_archive.outputs.archive_file }}
retention-days: 1
mac:
needs: [setup, docconvert]
name: Mac
runs-on: macos-latest
steps:
- name: Download Artifact with Configuration Information
uses: actions/download-artifact@v4
with:
name: ${{ env.CONFIG_ARTIFACT }}
- name: Extract Configuration Information and Store in Step Outputs
id: store_config
run: |
name=`sed -E -n -e 's/name= //p' $CONFIG_ARTIFACT_PATH`
echo "name=$name" >> $GITHUB_OUTPUT
prog=`sed -E -n -e 's/prog= //p' $CONFIG_ARTIFACT_PATH`
echo "prog=$prog" >> $GITHUB_OUTPUT
version=`sed -E -n -e 's/version= //p' $CONFIG_ARTIFACT_PATH`
echo "version=$version" >> $GITHUB_OUTPUT
# Need commit history and tags for scripts/version.sh to work as expected
# so use 0 for fetch-depth.
- name: Clone Project
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Download Artifact with Converted Documents
uses: actions/download-artifact@v4
with:
name: ${{ env.DOC_ARTIFACT }}
- name: Extract Converted Documents
run: |
tar -xf ${{ env.DOC_ARTIFACT_PATH }}
# An SDK that supports building x86_64 and arm64 objects is currently
# necessary unless the default list of architectures, ARCHS, in
# Makefile.osx is overridden. If the default SDK does not handle that,
# setting SDKROOT to point to an installed SDK that does would be one
# workaround. Override the default OPT (-O2) to get the equivalent of
# what --enable-release does for builds using configure.
- name: Create Mac Archive
id: create_mac_archive
run: |
cd src
env OPT="-O2 -DNDEBUG" make -f Makefile.osx dist
archive_prefix=${{ steps.store_config.outputs.name }}-${{ steps.store_config.outputs.version }}-osx
echo "archive_file=${archive_prefix}.dmg" >> $GITHUB_OUTPUT
- name: Create Artifact with Mac Archive Path
run: |
echo archive_path= '${{ steps.create_mac_archive.outputs.archive_file }}' > $MAC_ARTIFACT_PATH
- name: Upload Artifact with Mac Archive Path
uses: actions/upload-artifact@v4
with:
name: ${{ env.MAC_ARTIFACT }}
path: ${{ env.MAC_ARTIFACT_PATH }}
retention-days: 1
- name: Upload Mac Archive as Artifact
uses: actions/upload-artifact@v4
with:
name: ${{ env.MAC_ARCHIVE_ARTIFACT }}
path: ${{ steps.create_mac_archive.outputs.archive_file }}
retention-days: 1
_3ds:
needs: [setup, docconvert]
name: Nintendo 3DS
runs-on: ubuntu-latest
container: devkitpro/devkitarm
steps:
- name: Download Artifact with Configuration Information
uses: actions/download-artifact@v4
with:
name: ${{ env.CONFIG_ARTIFACT }}
- name: Extract Configuration Information and Store in Step Outputs
id: store_config
run: |
name=`sed -E -n -e 's/name= //p' $CONFIG_ARTIFACT_PATH`
echo "name=$name" >> $GITHUB_OUTPUT
prog=`sed -E -n -e 's/prog= //p' $CONFIG_ARTIFACT_PATH`
echo "prog=$prog" >> $GITHUB_OUTPUT
version=`sed -E -n -e 's/version= //p' $CONFIG_ARTIFACT_PATH`
echo "version=$version" >> $GITHUB_OUTPUT
- name: Clone Project
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Download Artifact with Converted Documents
uses: actions/download-artifact@v4
with:
name: ${{ env.DOC_ARTIFACT }}
- name: Extract Converted Documents
run: |
tar -xf ${{ env.DOC_ARTIFACT_PATH }}
- name: Build Nintendo 3DS (3dsx)
id: create_nintendo_3ds_3dsx
shell: bash
run: |
pushd src/
make -f Makefile.3ds
popd
test -e src/${{ steps.store_config.outputs.prog }}.3dsx
- name: Setup cxitool
shell: bash
run: |
apt-get update && apt-get install -y build-essential automake autoconf autotools-dev
git clone -b cxi-stuff https://github.com/devkitPro/3dstools/
pushd 3dstools/
./autogen.sh
./configure
make install
popd
- name: Setup makerom
shell: bash
run: |
apt-get update && apt-get install -y build-essential libmbedtls-dev liblzma-dev libyaml-dev
git clone https://github.com/3DSGuy/Project_CTR/
pushd Project_CTR/makerom
make deps
make
cp -rv bin/makerom /usr/local/bin
popd
# The quoting to get prog may be too simple-minded: what if there
# are single quotes in the steps.*.outputs.* stuff. Restrict what's
# passed to cxitool's --name option to at most 8 characters since that
# is a limitation of that tool.
- name: Build Nintendo 3DS (cia)
id: create_nintendo_3ds_cia
shell: bash
run: |
pushd src/
prog='${{ steps.store_config.outputs.prog }}'
procname=`echo "$prog" | head -c 8`
test -e "$prog".3dsx
cxitool --name "$procname" "$prog".3dsx "$prog".cxi
makerom -v -f cia -o "$prog".cia -target t -i "$prog".cxi:0:0 -ignoresign -icon icon.smdh
test -e "$prog".cia
popd
- name: Create Nintendo 3DS Archive
id: create_nintendo_3ds_archive
shell: bash
run: |
archive_prefix=${{ steps.store_config.outputs.name }}-${{ steps.store_config.outputs.version }}
echo "archive_file=${archive_prefix}-3ds.zip" >> $GITHUB_OUTPUT
mkdir -v ${{ steps.store_config.outputs.prog }}/
cp -v src/${{ steps.store_config.outputs.prog }}.3dsx ${archive_prefix}.3dsx
cp -v src/${{ steps.store_config.outputs.prog }}.cia ${archive_prefix}.cia
cp -rv lib ${{ steps.store_config.outputs.prog }}/
zip -r ${archive_prefix}-3ds.zip ${archive_prefix}.3dsx ${archive_prefix}.cia ${{ steps.store_config.outputs.prog }}/
- name: Create Artifact with Nintendo 3DS Archive Path
run: |
echo archive_path= '${{ steps.create_nintendo_3ds_archive.outputs.archive_file }}' > $NIN_3DS_ARTIFACT_PATH
- name: Upload Artifact with Nintendo 3DS Archive Path
uses: actions/upload-artifact@v4
with:
name: ${{ env.NIN_3DS_ARTIFACT }}
path: ${{ env.NIN_3DS_ARTIFACT_PATH }}
retention-days: 1
- name: Upload Nintendo 3DS Archive as Artifact
uses: actions/upload-artifact@v4
with:
name: ${{ env.NIN_3DS_ARCHIVE_ARTIFACT }}
path: ${{ steps.create_nintendo_3ds_archive.outputs.archive_file }}
retention-days: 1
nds:
needs: [setup, docconvert]
name: Nintendo DS
runs-on: ubuntu-latest
container: devkitpro/devkitarm
steps:
- name: Download Artifact with Configuration Information
uses: actions/download-artifact@v4
with:
name: ${{ env.CONFIG_ARTIFACT }}
- name: Extract Configuration Information and Store in Step Outputs
id: store_config
run: |
name=`sed -E -n -e 's/name= //p' $CONFIG_ARTIFACT_PATH`
echo "name=$name" >> $GITHUB_OUTPUT
prog=`sed -E -n -e 's/prog= //p' $CONFIG_ARTIFACT_PATH`
echo "prog=$prog" >> $GITHUB_OUTPUT
version=`sed -E -n -e 's/version= //p' $CONFIG_ARTIFACT_PATH`
echo "version=$version" >> $GITHUB_OUTPUT
- name: Clone Project
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Download Artifact with Converted Documents
uses: actions/download-artifact@v4
with:
name: ${{ env.DOC_ARTIFACT }}
- name: Extract Converted Documents
run: |
tar -xf ${{ env.DOC_ARTIFACT_PATH }}
- name: Create Nintendo DS Archive
id: create_nintendo_ds_archive
shell: bash
run: |
pushd src/
make -f Makefile.nds
popd
test -e src/${{ steps.store_config.outputs.prog }}.nds
archive_prefix=${{ steps.store_config.outputs.name }}-${{ steps.store_config.outputs.version }}
echo "archive_file=${archive_prefix}-nds.zip" >> $GITHUB_OUTPUT
mkdir -v ${{ steps.store_config.outputs.prog }}/
cp -v src/${{ steps.store_config.outputs.prog }}.nds ${archive_prefix}.nds
cp -rv lib ${{ steps.store_config.outputs.prog }}/
zip -r ${archive_prefix}-nds.zip ${archive_prefix}.nds ${{ steps.store_config.outputs.prog }}/
- name: Create Artifact with Nintendo DS Archive Path
run: |
echo archive_path= '${{ steps.create_nintendo_ds_archive.outputs.archive_file }}' > $NIN_DS_ARTIFACT_PATH
- name: Upload Artifact with Nintendo DS Archive Path
uses: actions/upload-artifact@v4
with:
name: ${{ env.NIN_DS_ARTIFACT }}
path: ${{ env.NIN_DS_ARTIFACT_PATH }}
retention-days: 1
- name: Upload Nintendo DS Archive as Artifact
uses: actions/upload-artifact@v4
with:
name: ${{ env.NIN_DS_ARCHIVE_ARTIFACT }}
path: ${{ steps.create_nintendo_ds_archive.outputs.archive_file }}
retention-days: 1
release:
needs: [ setup, source, windows, mac, _3ds, nds ]
name: Create GitHub Release
runs-on: ubuntu-latest
steps:
- name: Download Artifact with Configuration Information
uses: actions/download-artifact@v4
with:
name: ${{ env.CONFIG_ARTIFACT }}
- name: Extract Configuration Information and Store in Step Outputs
id: store_config
run: |
version=`sed -E -n -e 's/version= //p' $CONFIG_ARTIFACT_PATH`
echo "version=$version" >> $GITHUB_OUTPUT
prerelease=`sed -E -n -e 's/prerelease= //p' $CONFIG_ARTIFACT_PATH`
echo "prerelease=$prerelease" >> $GITHUB_OUTPUT
draft=`sed -E -n -e 's/draft= //p' $CONFIG_ARTIFACT_PATH`
echo "draft=$draft" >> $GITHUB_OUTPUT
- name: Download Artifact with Source Archive Path
uses: actions/download-artifact@v4
with:
name: ${{ env.SRC_ARTIFACT }}
- name: Extract Source Archive Path and Store in Step Outputs
id: store_src
run: |
archive_path=`sed -E -n -e 's/archive_path= //p' $SRC_ARTIFACT_PATH`
echo "archive_path=$archive_path" >> $GITHUB_OUTPUT
- name: Download Artifact with Source Archive
uses: actions/download-artifact@v4
with:
name: ${{ env.SRC_ARCHIVE_ARTIFACT }}
- name: Download Artifact with Windows Archive Path
uses: actions/download-artifact@v4
with:
name: ${{ env.WIN_ARTIFACT }}
- name: Extract Windows Archive Path and Store in Step Outputs
id: store_win
run: |
archive_path=`sed -E -n -e 's/archive_path= //p' $WIN_ARTIFACT_PATH`
echo "archive_path=$archive_path" >> $GITHUB_OUTPUT
- name: Download Artifact with Windows Archive
uses: actions/download-artifact@v4
with:
name: ${{ env.WIN_ARCHIVE_ARTIFACT }}
- name: Download Artifact with Mac Archive Path
uses: actions/download-artifact@v4
with:
name: ${{ env.MAC_ARTIFACT }}
- name: Extract Mac Archive Path and Store in Step Outputs
id: store_mac
run: |
archive_path=`sed -E -n -e 's/archive_path= //p' $MAC_ARTIFACT_PATH`
echo "archive_path=$archive_path" >> $GITHUB_OUTPUT
- name: Download Artifact with Mac Archive
uses: actions/download-artifact@v4
with:
name: ${{ env.MAC_ARCHIVE_ARTIFACT }}
- name: Download Artifact with Nintendo 3DS Archive Path
uses: actions/download-artifact@v4
with:
name: ${{ env.NIN_3DS_ARTIFACT }}
- name: Extract Nintendo 3DS Archive Path and Store in Step Outputs
id: store_3ds
run: |
archive_path=`sed -E -n -e 's/archive_path= //p' $NIN_3DS_ARTIFACT_PATH`
echo "archive_path=$archive_path" >> $GITHUB_OUTPUT
- name: Download Artifact with Nintendo 3DS Archive
uses: actions/download-artifact@v4
with:
name: ${{ env.NIN_3DS_ARCHIVE_ARTIFACT }}
- name: Download Artifact with Nintendo DS Archive Path
uses: actions/download-artifact@v4
with:
name: ${{ env.NIN_DS_ARTIFACT }}
- name: Extract Nintendo DS Archive Path and Store in Step Outputs
id: store_ds
run: |
archive_path=`sed -E -n -e 's/archive_path= //p' $NIN_DS_ARTIFACT_PATH`
echo "archive_path=$archive_path" >> $GITHUB_OUTPUT
- name: Download Artifact with Nintendo DS Archive
uses: actions/download-artifact@v4
with:
name: ${{ env.NIN_DS_ARCHIVE_ARTIFACT }}
- name: Populate Release
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ steps.store_config.outputs.version }}
name: ${{ steps.store_config.outputs.version }}
target_commitish: ${{ github.sha }}
draft: ${{ steps.store_config.outputs.draft }}
prerelease: ${{ steps.store_config.outputs.prerelease }}
files: |
${{ steps.store_src.outputs.archive_path }}
${{ steps.store_win.outputs.archive_path }}
${{ steps.store_mac.outputs.archive_path }}
${{ steps.store_3ds.outputs.archive_path }}
${{ steps.store_ds.outputs.archive_path }}
token: ${{ secrets.GITHUB_TOKEN }}