Skip to content

Commit e73fabe

Browse files
committed
Add release workflow (testing)
1 parent cd56397 commit e73fabe

1 file changed

Lines changed: 82 additions & 0 deletions

File tree

.github/workflows/release.yml

Lines changed: 82 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,82 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v*'
7+
workflow_dispatch: # Allow manual trigger for testing
8+
9+
jobs:
10+
build_macos:
11+
runs-on: macos-latest
12+
steps:
13+
- uses: actions/checkout@v4
14+
with:
15+
submodules: true
16+
17+
- name: Configure
18+
run: cmake -B build -S . -DCMAKE_BUILD_TYPE=Release
19+
20+
- name: Build
21+
run: cmake --build build --parallel
22+
23+
- name: Package
24+
run: |
25+
cd build
26+
zip -r RocketEditor-macOS.zip RocketEditor.app
27+
28+
- name: Upload artifact
29+
uses: actions/upload-artifact@v4
30+
with:
31+
name: RocketEditor-macOS
32+
path: build/RocketEditor-macOS.zip
33+
34+
build_windows:
35+
runs-on: windows-latest
36+
steps:
37+
- uses: actions/checkout@v4
38+
with:
39+
submodules: true
40+
41+
- name: Configure
42+
run: cmake -B build -S . -DCMAKE_BUILD_TYPE=Release
43+
44+
- name: Build
45+
run: cmake --build build --config Release --parallel
46+
47+
- name: Package
48+
shell: pwsh
49+
run: |
50+
New-Item -ItemType Directory -Force -Path package
51+
Copy-Item build/Release/RocketEditor.exe package/
52+
Copy-Item external/bass/win64/bass.dll package/
53+
Compress-Archive -Path package/* -DestinationPath RocketEditor-Windows.zip
54+
55+
- name: Upload artifact
56+
uses: actions/upload-artifact@v4
57+
with:
58+
name: RocketEditor-Windows
59+
path: RocketEditor-Windows.zip
60+
61+
release:
62+
needs: [build_macos, build_windows]
63+
runs-on: ubuntu-latest
64+
permissions:
65+
contents: write
66+
steps:
67+
- name: Download macOS artifact
68+
uses: actions/download-artifact@v4
69+
with:
70+
name: RocketEditor-macOS
71+
72+
- name: Download Windows artifact
73+
uses: actions/download-artifact@v4
74+
with:
75+
name: RocketEditor-Windows
76+
77+
- name: Create Release
78+
uses: softprops/action-gh-release@v1
79+
with:
80+
files: |
81+
RocketEditor-macOS.zip
82+
RocketEditor-Windows.zip

0 commit comments

Comments
 (0)