-
Notifications
You must be signed in to change notification settings - Fork 0
48 lines (40 loc) · 1.34 KB
/
Build-PreRelease.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
name: Build CTRL
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
Build-PreRelease:
runs-on: ubuntu-latest
permissions:
packages: write
contents: write
container:
image: 'devkitpro/devkitarm'
steps:
- name: Checkout
uses: actions/checkout@v4
with:
persist-credentials: false
- name: Configure CMake
run: cmake -B ${{github.workspace}}/Build -G "Unix Makefiles" -DCMAKE_TOOLCHAIN_FILE="$DEVKITPRO/cmake/3DS.cmake" -DCMAKE_BUILD_TYPE=Release
- name: Build
run: cmake --build ${{github.workspace}}/Build --config Release
- name: Install
run: cmake --install ${{github.workspace}}/Build --prefix ${{github.workspace}}/Build/Release
- name: Make ZIP
run: |
(cd ${{github.workspace}}/Build/Release && zip -r CTRL-${{github.sha}}.zip .)
mv ${{github.workspace}}/Build/Release/CTRL-${{github.sha}}.zip .
- name: Upload Assets
uses: softprops/action-gh-release@v2
with:
name: PreRelease-${{github.sha}}
files: CTRL-${{github.sha}}.zip
fail_on_unmatched_files: true
tag_name: PreRelease-${{github.run_id}}
prerelease: true
make_latest: true
token: ${{secrets.GITHUB_TOKEN}}
generate_release_notes: true