|
1 | | -# This workflow will build a .NET project |
2 | | -# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-net |
| 1 | +# Build and validate StreamDeck-Tools across all supported TFMs and platforms. |
| 2 | +# netstandard2.0 builds on all platforms with any .NET SDK. |
| 3 | +# net48 is Windows-only (requires .NET Framework targeting pack). |
| 4 | +# net8.0 and net10.0 build on Windows, macOS, and Linux. |
3 | 5 |
|
4 | 6 | name: .NET |
5 | 7 |
|
6 | 8 | on: |
7 | 9 | push: |
8 | | - branches: [ "master" ] |
| 10 | + branches: [ "master", "feature/**" ] |
9 | 11 | pull_request: |
10 | 12 | branches: [ "master" ] |
11 | 13 |
|
12 | 14 | jobs: |
13 | | - build: |
14 | | - |
| 15 | + build-windows: |
| 16 | + name: Windows (netstandard2.0 + net48 + net8.0 + net10.0) |
15 | 17 | runs-on: windows-latest |
16 | | - |
17 | 18 | steps: |
18 | | - - uses: actions/checkout@v3 |
| 19 | + - uses: actions/checkout@v4 |
19 | 20 | - name: Setup .NET |
20 | | - uses: actions/setup-dotnet@v3 |
| 21 | + uses: actions/setup-dotnet@v4 |
21 | 22 | with: |
22 | | - dotnet-version: 8.0.x |
| 23 | + dotnet-version: | |
| 24 | + 8.0.x |
| 25 | + 10.0.x |
23 | 26 | - name: Restore dependencies |
24 | 27 | run: dotnet restore |
25 | 28 | - name: Build |
26 | | - run: dotnet build --no-restore |
| 29 | + run: dotnet build --no-restore --configuration Release |
27 | 30 | - name: Test |
28 | | - run: dotnet test --no-build --verbosity normal |
| 31 | + run: dotnet test --no-build --configuration Release --verbosity normal |
| 32 | + |
| 33 | + build-macos: |
| 34 | + name: macOS (netstandard2.0 + net8.0 + net10.0) |
| 35 | + runs-on: macos-latest |
| 36 | + steps: |
| 37 | + - uses: actions/checkout@v4 |
| 38 | + - name: Setup .NET |
| 39 | + uses: actions/setup-dotnet@v4 |
| 40 | + with: |
| 41 | + dotnet-version: | |
| 42 | + 8.0.x |
| 43 | + 10.0.x |
| 44 | + - name: Build netstandard2.0 |
| 45 | + run: dotnet build barraider-sdtools/barraider-sdtools.csproj --configuration Release --framework netstandard2.0 |
| 46 | + - name: Build net8.0 |
| 47 | + run: dotnet build barraider-sdtools/barraider-sdtools.csproj --configuration Release --framework net8.0 |
| 48 | + - name: Build net10.0 |
| 49 | + run: dotnet build barraider-sdtools/barraider-sdtools.csproj --configuration Release --framework net10.0 |
| 50 | + |
| 51 | + build-linux: |
| 52 | + name: Linux (netstandard2.0 + net8.0 + net10.0) |
| 53 | + runs-on: ubuntu-latest |
| 54 | + steps: |
| 55 | + - uses: actions/checkout@v4 |
| 56 | + - name: Setup .NET |
| 57 | + uses: actions/setup-dotnet@v4 |
| 58 | + with: |
| 59 | + dotnet-version: | |
| 60 | + 8.0.x |
| 61 | + 10.0.x |
| 62 | + - name: Build netstandard2.0 |
| 63 | + run: dotnet build barraider-sdtools/barraider-sdtools.csproj --configuration Release --framework netstandard2.0 |
| 64 | + - name: Build net8.0 |
| 65 | + run: dotnet build barraider-sdtools/barraider-sdtools.csproj --configuration Release --framework net8.0 |
| 66 | + - name: Build net10.0 |
| 67 | + run: dotnet build barraider-sdtools/barraider-sdtools.csproj --configuration Release --framework net10.0 |
0 commit comments