Migrate to .NET 7
Recipe ID
OpenRewrite.Recipes.CSharp.Migration.Dotnet.Net7.UpgradeToDotNet7ArtifactOpenRewrite.Recipes.CSharp.Migration.DotnetMigrate C# projects to .NET 7, applying necessary API changes. See https://learn.microsoft.com/en-us/dotnet/core/compatibility/7.0.
Composite recipecsharpdotnetmigrationProprietary
Usage
This recipe has no required configuration options. You’ll need the Moderne CLI configured before running the command below.
mod run . --recipe OpenRewrite.Recipes.CSharp.Migration.Dotnet.Net7.UpgradeToDotNet7If the recipe isn’t available locally, install it with:
mod config recipes nuget install OpenRewrite.Recipes.CSharp.Migration.DotnetDefinition
This recipe runs the following recipes in order.
- Migrate to .NET 6
OpenRewrite.Recipes.CSharp.Migration.Dotnet.Net6.UpgradeToDotNet6 - Change .NET target framework
OpenRewrite.CSharp.Recipes.ChangeDotNetTargetFramework - Upgrade NuGet package version
OpenRewrite.CSharp.Recipes.UpgradeNuGetPackageVersion - Upgrade NuGet package version
OpenRewrite.CSharp.Recipes.UpgradeNuGetPackageVersion - Upgrade NuGet package version
OpenRewrite.CSharp.Recipes.UpgradeNuGetPackageVersion - Upgrade NuGet package version
OpenRewrite.CSharp.Recipes.UpgradeNuGetPackageVersion - Upgrade NuGet package version
OpenRewrite.CSharp.Recipes.UpgradeNuGetPackageVersion - Ensure csproj attestation
OpenRewrite.CSharp.Recipes.EnsureCsprojAttestation - Change type
OpenRewrite.Recipes.CSharp.Migration.Dotnet.ChangeType - Delete method argument
OpenRewrite.Recipes.CSharp.Migration.Dotnet.DeleteMethodArgument - Delete method argument
OpenRewrite.Recipes.CSharp.Migration.Dotnet.DeleteMethodArgument - Delete method argument
OpenRewrite.Recipes.CSharp.Migration.Dotnet.DeleteMethodArgument - Delete method argument
OpenRewrite.Recipes.CSharp.Migration.Dotnet.DeleteMethodArgument - Delete method argument
OpenRewrite.Recipes.CSharp.Migration.Dotnet.DeleteMethodArgument - Delete method argument
OpenRewrite.Recipes.CSharp.Migration.Dotnet.DeleteMethodArgument - Delete method argument
OpenRewrite.Recipes.CSharp.Migration.Dotnet.DeleteMethodArgument - Delete method argument
OpenRewrite.Recipes.CSharp.Migration.Dotnet.DeleteMethodArgument - Delete method argument
OpenRewrite.Recipes.CSharp.Migration.Dotnet.DeleteMethodArgument - Delete method argument
OpenRewrite.Recipes.CSharp.Migration.Dotnet.DeleteMethodArgument - Delete method argument
OpenRewrite.Recipes.CSharp.Migration.Dotnet.DeleteMethodArgument - Delete method argument
OpenRewrite.Recipes.CSharp.Migration.Dotnet.DeleteMethodArgument - Delete method argument
OpenRewrite.Recipes.CSharp.Migration.Dotnet.DeleteMethodArgument - Delete method argument
OpenRewrite.Recipes.CSharp.Migration.Dotnet.DeleteMethodArgument - Delete method argument
OpenRewrite.Recipes.CSharp.Migration.Dotnet.DeleteMethodArgument - Delete method argument
OpenRewrite.Recipes.CSharp.Migration.Dotnet.DeleteMethodArgument - Delete method argument
OpenRewrite.Recipes.CSharp.Migration.Dotnet.DeleteMethodArgument - Delete method argument
OpenRewrite.Recipes.CSharp.Migration.Dotnet.DeleteMethodArgument - Change method name
OpenRewrite.Recipes.CSharp.Migration.Dotnet.ChangeMethodName - Find insecure
Rfc2898DeriveBytesconstructors (SYSLIB0041)OpenRewrite.Recipes.CSharp.Migration.Dotnet.Net7.FindRfc2898InsecureCtors - Find obsolete
SslProtocols.Tls/Tls11usage (SYSLIB0039)OpenRewrite.Recipes.CSharp.Migration.Dotnet.Net7.FindObsoleteSslProtocols - Use LINQ Order() and OrderDescending()
OpenRewrite.Recipes.CSharp.Migration.Dotnet.Net7.UseLinqOrder - Use ArgumentException.ThrowIfNullOrEmpty()
OpenRewrite.Recipes.CSharp.Migration.Dotnet.Net7.UseThrowIfNullOrEmpty - Use ArgumentOutOfRangeException.ThrowIfNegative()
OpenRewrite.Recipes.CSharp.Migration.Dotnet.Net7.UseThrowIfNegative - Use ArgumentOutOfRangeException.ThrowIfNegativeOrZero()
OpenRewrite.Recipes.CSharp.Migration.Dotnet.Net7.UseThrowIfNegativeOrZero