Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: Improvements in CI workflow #60

Merged
merged 16 commits into from
Nov 24, 2024
Merged
2 changes: 1 addition & 1 deletion .github/workflows/dotnet-format.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.0.x
dotnet-version: 9.0.x

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, just want to confirm though that given we're now using the .NET 9 SDK that we're still releasing a .NET 8 library?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The target framework remains net8.0 in the csproj TargetFrameworks>net8.0;</TargetFrameworks>, so my understanding is that it all still builds as .net 8 library, even if we use SDK 9 to build it.


- name: Format
working-directory: ./src
Expand Down
71 changes: 64 additions & 7 deletions .github/workflows/dotnet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,23 +19,80 @@ jobs:
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.0.x
dotnet-version: 9.0.x
- name: Setup JDK
uses: actions/setup-java@v4
with:
distribution: 'microsoft'
java-version: '17'
- name: Setup Android SDK
uses: android-actions/setup-android@v3

# Pre-build setup
- name: Restore workloads
working-directory: ./src
run: dotnet workload restore
- name: Restore dependencies

# Raygun.Blazor
- name: Build Raygun.Blazor
continue-on-error: true
working-directory: ./src
run: dotnet build Raygun.Blazor/Raygun.Blazor.csproj
# Raygun.Blazor tests
- name: Test Raygun.Blazor
continue-on-error: true
working-directory: ./src
run: dotnet test Raygun.Tests.Blazor/Raygun.Tests.Blazor.csproj

# Raygun.Blazor.Server
- name: Build Raygun.Blazor.Server
continue-on-error: true
working-directory: ./src
run: dotnet build Raygun.Blazor.Server/Raygun.Blazor.Server.csproj
# Raygun.Blazor.Server tests
- name: Test Raygun.Blazor.Server
continue-on-error: true
working-directory: ./src
run: dotnet test Raygun.Tests.Blazor.Server/Raygun.Tests.Blazor.Server.csproj
# Raygun.Blazor.Server sample
- name: Build Raygun.Samples.Blazor.Server
continue-on-error: true
working-directory: ./src
run: dotnet build Raygun.Samples.Blazor.Server/Raygun.Samples.Blazor.Server.csproj

# Raygun.Blazor.WebAssembly
- name: Build Raygun.Blazor.WebAssembly
continue-on-error: true
working-directory: ./src
run: dotnet build Raygun.Blazor.WebAssembly/Raygun.Blazor.WebAssembly.csproj
# Raygun.Blazor.WebAssembly sample
- name: Build Raygun.Samples.Blazor.WebAssembly
continue-on-error: true
working-directory: ./src
run: dotnet build Raygun.Samples.Blazor.Server/Raygun.Samples.Blazor.Server.csproj

# Raygun.Blazor.Maui
- name: Build Raygun.Blazor.Maui
continue-on-error: true
working-directory: ./src
run: dotnet build Raygun.Blazor.Maui/Raygun.Blazor.Maui.csproj
# Raygun.Blazor.Maui Windows sample
- name: Build Raygun.Samples.Blazor.Maui Windows
continue-on-error: true
working-directory: ./src
run: dotnet build Raygun.Samples.Blazor.Maui/Raygun.Samples.Blazor.Maui.csproj -f net8.0-windows10.0.19041.0
# Raygun.Blazor.Maui Android sample
- name: Build Raygun.Samples.Blazor.Maui Android
continue-on-error: true
working-directory: ./src
run: dotnet restore
- name: Build
run: dotnet build Raygun.Samples.Blazor.Maui/Raygun.Samples.Blazor.Maui.csproj -f net8.0-android
# Raygun.Blazor.Maui iOS sample
- name: Build Raygun.Samples.Blazor.Maui ios
continue-on-error: true
working-directory: ./src
run: dotnet build --no-restore
- name: Test
run: dotnet build Raygun.Samples.Blazor.Maui/Raygun.Samples.Blazor.Maui.csproj -f net8.0-ios
# Raygun.Blazor.Maui macOS sample
- name: Build Raygun.Samples.Blazor.Maui maccatalyst
continue-on-error: true
working-directory: ./src
run: dotnet test
run: dotnet build Raygun.Samples.Blazor.Maui/Raygun.Samples.Blazor.Maui.csproj -f net8.0-maccatalyst
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,8 @@

<!-- For appsettings.json -->
<ItemGroup>
<PackageReference Include="Microsoft.Extensions.Configuration.Binder" Version="8.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="8.0.0" />
<PackageReference Include="Microsoft.Extensions.Configuration.Binder" Version="8.0.2" />
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="8.0.1" />
</ItemGroup>

<ItemGroup>
Expand Down
2 changes: 1 addition & 1 deletion src/global.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"sdk": {
"version": "8.0.300",
"version": "9.0.100",
"rollForward": "latestFeature"
}
}
Loading