Skip to content

Commit f7b0f05

Browse files
committed
添加 GitHub Actions 工作流以支持多架构构建
1 parent b9d2ebd commit f7b0f05

File tree

1 file changed

+40
-0
lines changed

1 file changed

+40
-0
lines changed

.github/workflows/build.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: Build
2+
3+
on:
4+
workflow_dispatch:
5+
6+
jobs:
7+
run:
8+
name: build
9+
runs-on: windows-latest
10+
strategy:
11+
matrix:
12+
architecture: [x64, arm64]
13+
edition: [CommandLine, Universal]
14+
15+
16+
steps:
17+
- name: Checkout code
18+
uses: actions/checkout@v4
19+
20+
- name: Setup .NET
21+
uses: actions/setup-dotnet@v4
22+
with:
23+
dotnet-version: 9.0.x
24+
25+
- name: Setup MSBuild
26+
uses: microsoft/setup-msbuild@v2
27+
28+
- name: Publish Aot
29+
env:
30+
RuntimeIdentifier: win-${{ matrix.architecture }}
31+
PublishDir: ./publish/win-${{ matrix.architecture }}
32+
run: |
33+
cd ./FluentLauncher.${{ matrix.edition }}Installer
34+
dotnet publish --configuration Release --self-contained true --runtime win-${{ matrix.architecture }} --output $PublishDir --nologo
35+
36+
- name: upload to artifacts
37+
uses: actions/upload-artifact@v4
38+
with:
39+
name: win-${{ matrix.architecture }}
40+
path: "FluentLauncher.${{ matrix.edition }}Installer\\publish\\win-${{ matrix.architecture }}\\FluentLauncher.${{ matrix.edition }}Installer.exe"

0 commit comments

Comments
 (0)