-
Notifications
You must be signed in to change notification settings - Fork 0
110 lines (93 loc) · 2.89 KB
/
Copy pathrelease.yml
File metadata and controls
110 lines (93 loc) · 2.89 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
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
name: Release
on:
push:
tags:
- 'v*'
permissions:
contents: write
env:
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true
jobs:
build:
strategy:
fail-fast: false
matrix:
include:
- os: windows-latest
rid: win-x64
archive: zip
- os: ubuntu-latest
rid: linux-x64
archive: tar.gz
- os: macos-latest
rid: osx-x64
archive: tar.gz
- os: macos-latest
rid: osx-arm64
archive: tar.gz
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v5
with:
submodules: recursive
fetch-depth: 0
- name: Setup .NET
uses: actions/setup-dotnet@v5
with:
dotnet-version: '10.0.x'
dotnet-quality: 'preview'
- name: Extract version from tag
id: version
shell: bash
run: |
TAG="${GITHUB_REF#refs/tags/v}"
echo "version=$TAG" >> "$GITHUB_OUTPUT"
echo "Building version: $TAG"
- name: Publish
run: >
dotnet publish ReScene.Manager/ReScene.Manager.csproj
-c Release
-r ${{ matrix.rid }}
--self-contained
-p:Version=${{ steps.version.outputs.version }}
-p:PublishSingleFile=true
-p:IncludeNativeLibrariesForSelfExtract=true
-o publish
- name: Package (zip)
if: matrix.archive == 'zip'
shell: pwsh
run: Compress-Archive -Path publish/* -DestinationPath ReSceneManager-${{ steps.version.outputs.version }}-${{ matrix.rid }}.zip
- name: Package (tar.gz)
if: matrix.archive == 'tar.gz'
shell: bash
run: |
chmod +x "publish/ReScene.Manager"
tar -czf "ReSceneManager-${{ steps.version.outputs.version }}-${{ matrix.rid }}.tar.gz" -C publish .
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: ReSceneManager-${{ matrix.rid }}
path: ReSceneManager-*-${{ matrix.rid }}.*
release:
runs-on: ubuntu-latest
needs: build
steps:
- name: Checkout
uses: actions/checkout@v5
with:
submodules: recursive
fetch-depth: 0
- name: Download artifacts
uses: actions/download-artifact@v4
with:
path: artifacts
merge-multiple: true
- name: Create GitHub Release
uses: softprops/action-gh-release@v3
with:
generate_release_notes: true
files: artifacts/ReSceneManager-*.*
# ReScene.Lib is released independently, on its OWN changes — NOT auto-tagged/released whenever the
# app is tagged. Releasing the lib with no changes just because the app shipped is pointless, so the
# former csproj-version-equals-tag gate + submodule tag/release steps were removed (2026-07-21).