mirror of
https://github.com/BeyondDimension/SteamTools.git
synced 2026-10-25 11:39:56 +08:00
75 lines
2.4 KiB
YAML
75 lines
2.4 KiB
YAML
name: .NET Build
|
|
|
|
on:
|
|
push:
|
|
branches: [ main, develop ]
|
|
pull_request:
|
|
branches: [ main, develop ]
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ${{ matrix.os }}
|
|
strategy:
|
|
matrix:
|
|
# os: [ windows-latest, macOS-latest, ubuntu-latest ]
|
|
os: [ windows-latest ]
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- name: Setup .NET 5
|
|
uses: actions/setup-dotnet@v1
|
|
with:
|
|
dotnet-version: 5.0.x
|
|
- name: Setup .NET 6
|
|
uses: actions/setup-dotnet@v1
|
|
with:
|
|
dotnet-version: 6.0.100-rc.2.21505.57
|
|
|
|
- name: Install macOS SDK(macOS)
|
|
if: matrix.os == 'macOS-latest'
|
|
run: sudo dotnet workload install macos
|
|
|
|
- name: Install macOS SDK(Windows)
|
|
if: matrix.os == 'windows-latest'
|
|
run: dotnet workload install macos
|
|
|
|
- name: Install Maui(Windows)
|
|
if: matrix.os == 'windows-latest'
|
|
run: dotnet workload install maui
|
|
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v2
|
|
- name: Checkout submodules
|
|
run: git submodule update --init --recursive
|
|
|
|
- name: dotnet info
|
|
run: dotnet --info
|
|
|
|
- name: dotnet restore SteamToolsV2+.sln
|
|
if: matrix.os == 'windows-latest'
|
|
run: dotnet restore ./SteamToolsV2+.sln
|
|
|
|
- name: dotnet restore SteamToolsV2+.Linux.sln
|
|
if: matrix.os == 'ubuntu-latest'
|
|
run: dotnet restore ./SteamToolsV2+.Linux.slnf
|
|
|
|
- name: dotnet restore SteamToolsV2+.Mac.sln
|
|
if: matrix.os == 'macOS-latest'
|
|
run: dotnet restore ./SteamToolsV2+.Mac.slnf
|
|
|
|
- name: dotnet AvaloniaApp build
|
|
run: dotnet build ./src/ST.Client.Desktop.Avalonia.App/ST.Client.Avalonia.App.csproj
|
|
- name: dotnet CommonUnit build
|
|
run: dotnet build ./tests/Common.UnitTest/Common.UnitTest.csproj
|
|
- name: dotnet ST.Client.UnitTest build
|
|
run: dotnet build ./tests/ST.Client.UnitTest/ST.Client.UnitTest.csproj
|
|
# - name: dotnet ST.Client.Desktop.UnitTest build
|
|
# run: dotnet build ./tests/ST.Client.Desktop.UnitTest/ST.Client.Desktop.UnitTest.csproj
|
|
|
|
- name: dotnet CommonUnit test
|
|
run: dotnet test ./tests/Common.UnitTest/Common.UnitTest.csproj
|
|
- name: dotnet ST.Client.UnitTest test
|
|
run: dotnet test ./tests/ST.Client.UnitTest/ST.Client.UnitTest.csproj
|
|
# - name: dotnet ST.Client.Desktop.UnitTest test
|
|
# if: matrix.os != 'windows-latest'
|
|
# run: dotnet test ./tests/ST.Client.Desktop.UnitTest/ST.Client.Desktop.UnitTest.csproj
|