-
Notifications
You must be signed in to change notification settings - Fork 44
50 lines (36 loc) · 1.58 KB
/
CI.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
40
41
42
43
44
45
46
47
48
49
50
name: .NET
on:
push:
tags:
- v*
jobs:
build_cli:
env:
BUILD_CONFIG: 'Release'
CLI_PROJECT: 'RPGMakerDecrypter.Cli/RPGMakerDecrypter.Cli.csproj'
GUI_PROJECT: 'RPGMakerDecrypter.Gui/RPGMakerDecrypter.Gui.csproj'
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- name: Fetch tags
run: git fetch --all --tags
- name: Setup NuGet
uses: NuGet/setup-nuget@v1.0.5
- name: Setup .NET
uses: actions/setup-dotnet@v1
with:
dotnet-version: 6.0.x
- name: Restore dependencies
run: dotnet restore
- name: Build
run: dotnet build --configuration $Env:BUILD_CONFIG --no-restore
- name: Publish Linux CLI
run: dotnet publish $Env:CLI_PROJECT --configuration $Env:BUILD_CONFIG -r linux-x64 -p:PublishSingleFile=true -p:PublishTrimmed=true -p:TrimMode=Link --self-contained true --output $Env:GITHUB_WORKSPACE
- name: Publish Windows CLI
run: dotnet publish $Env:CLI_PROJECT --configuration $Env:BUILD_CONFIG -r win-x64 -p:PublishSingleFile=true -p:PublishTrimmed=true -p:TrimMode=Link --self-contained true --output $Env:GITHUB_WORKSPACE
- name: Publish Windows GUI
run: dotnet publish $Env:GUI_PROJECT --configuration $Env:BUILD_CONFIG -r win-x64 -p:PublishSingleFile=true --self-contained true --output $Env:GITHUB_WORKSPACE
- uses: ncipollo/release-action@v1.12.0
with:
bodyFile: CHANGELOG.MD
artifacts: "RPGMakerDecrypter-cli,RPGMakerDecrypter-cli.exe,RPGMakerDecrypter.exe"