Skip to content

Commit

Permalink
Add .NET 8 support (#165)
Browse files Browse the repository at this point in the history
  • Loading branch information
eduherminio authored Dec 2, 2023
1 parent 6a3b2aa commit 2ac1f9a
Showing 9 changed files with 20 additions and 14 deletions.
2 changes: 1 addition & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -2,7 +2,7 @@ version: 2.1
executors:
fileparser-executor:
docker:
- image: mcr.microsoft.com/dotnet/sdk:6.0
- image: mcr.microsoft.com/dotnet/sdk:8.0
working_directory: ~/FileParser

jobs:
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -28,7 +28,7 @@ jobs:
- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: 6.0.x
dotnet-version: 8.0.x

- name: Setup .NET 5 for sonar
if: matrix.os == 'windows-latest'
@@ -40,7 +40,7 @@ jobs:
uses: actions/setup-java@v4
if: matrix.os == 'windows-latest'
with:
java-version: 11
java-version: 17
distribution: 'zulu'

- name: '[Windows] Cache SonarCloud packages'
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -51,7 +51,7 @@ jobs:
- name: Setup .NET Core
uses: actions/setup-dotnet@v3
with:
dotnet-version: 6.0.x
dotnet-version: 8.0.x

- name: Set version to ${{ github.event.inputs.new_package_version }}
shell: pwsh
1 change: 0 additions & 1 deletion Directory.Build.props
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
<Project>

<PropertyGroup>
<TargetFramework>net6.0</TargetFramework>
<LangVersion>latest</LangVersion>
<Nullable>Enable</Nullable>
<ImplicitUsings>enable</ImplicitUsings>
2 changes: 1 addition & 1 deletion azure-pipelines.yml
Original file line number Diff line number Diff line change
@@ -9,7 +9,7 @@ schedules:
- main

variables:
SdkVersion: '6.0.x'
SdkVersion: '8.0.x'

stages:
- stage: CI
1 change: 1 addition & 0 deletions src/FileParser.Benchmark/FileParser.Benchmark.csproj
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<OutputType>Exe</OutputType>
</PropertyGroup>

12 changes: 12 additions & 0 deletions src/FileParser/FileParser.csproj
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net6.0;net8.0</TargetFrameworks>
</PropertyGroup>

<PropertyGroup>
<IncludeSymbols>true</IncludeSymbols>
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
@@ -17,8 +22,15 @@
<RepositoryType>git</RepositoryType>
<PublishRepositoryUrl>true</PublishRepositoryUrl>
<EmbedUntrackedSources>true</EmbedUntrackedSources>
<PackageReadmeFile>README.md</PackageReadmeFile>
</PropertyGroup>

<ItemGroup>
<None Include="..\..\README.md" Pack="true" PackagePath="">
<Link>Properties\README.md</Link>
</None>
</ItemGroup>

<PropertyGroup>
<DocumentationFile>bin\$(Configuration)\$(TargetFramework)\$(AssemblyName).xml</DocumentationFile>
<NoWarn>1591</NoWarn>
9 changes: 1 addition & 8 deletions src/FileParser/ParsingException.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
using System.Runtime.Serialization;

namespace FileParser
namespace FileParser
{
[Serializable]
public class ParsingException : Exception
{
private const string GenericMessage = "Exception triggered during parsing process";
@@ -18,9 +15,5 @@ public ParsingException(string message) : base(message ?? GenericMessage)
public ParsingException(string message, Exception inner) : base(message ?? GenericMessage, inner)
{
}

protected ParsingException(SerializationInfo info, StreamingContext context) : base(info, context)
{
}
}
}
1 change: 1 addition & 0 deletions tests/FileParser.Test/FileParser.Test.csproj
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<IsPackable>false</IsPackable>
</PropertyGroup>

0 comments on commit 2ac1f9a

Please sign in to comment.