-
Notifications
You must be signed in to change notification settings - Fork 13
57 lines (46 loc) · 1.52 KB
/
Copy pathrelease.yml
File metadata and controls
57 lines (46 loc) · 1.52 KB
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
name: Create GitHub Release
on:
push:
tags:
- 'v*'
jobs:
release:
runs-on: windows-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup .NET 6
uses: actions/setup-dotnet@v3
with:
dotnet-version: '6.0.x'
- name: Setup MSBuild
uses: microsoft/setup-msbuild@v1.1.3
- name: Restore NuGet packages
run: nuget restore SharpExt4.sln
# Build x86
- name: Build x86
run: msbuild SharpExt4.sln /p:Configuration=Release /p:Platform=x86
# Build x64
- name: Build x64
run: msbuild SharpExt4.sln /p:Configuration=Release /p:Platform=x64
# Zip x86 output
- name: Zip x86 build
run: Compress-Archive -Path Release\* -DestinationPath SharpExt4-x86-${{ github.ref_name }}.zip
shell: pwsh
# Zip x64 output
- name: Zip x64 build
run: Compress-Archive -Path x64\Release\* -DestinationPath SharpExt4-x64-${{ github.ref_name }}.zip
shell: pwsh
# Upload both zip files to GitHub Release
- name: Create GitHub Release and Upload Zips
uses: softprops/action-gh-release@v1
with:
tag_name: ${{ github.ref_name }}
name: ${{ github.ref_name }}
body: |
Release for version ${{ github.ref_name }}
files: |
SharpExt4-x86-${{ github.ref_name }}.zip
SharpExt4-x64-${{ github.ref_name }}.zip
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}