forked from Razzmatazzz/RemnantSaveGuardian
-
Notifications
You must be signed in to change notification settings - Fork 1
39 lines (34 loc) · 1.11 KB
/
dotnet.yml
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
# This workflow will build a .NET project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-net
name: .NET
on:
push:
tags:
- "[0-9]+.[0-9]+.[0-9]+"
workflow_dispatch:
jobs:
build:
runs-on: windows-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.0.x
- name: Build
shell: powershell
run: dotnet publish Remnant2SaveAnalyzer\Remnant2SaveAnalyzer.csproj -c Release --self-contained -r win-x64 "/p:Version=$env:TAG" "/p:AssemblyVersion=$env:TAG"
env:
TAG: ${{ github.ref_name }}
- name: Create release archive
shell: powershell
run: |
7z a "Remnant2SaveAnalyzer-$env:TAG.zip" .\Remnant2SaveAnalyzer\bin\Release\net8.0-windows7.0\win-x64\publish\*
env:
TAG: ${{ github.ref_name }}
- name: Create Release
uses: softprops/action-gh-release@v2
with:
files: Remnant2SaveAnalyzer-${{ github.ref_name }}.zip
body: "[CHANGELOG.md](CHANGELOG.md)"