Cake v2.0.0 RC 2 released

Published
Friday, 26 November 2021
Category
Release Notes
Author
augustoproiete

Version 2.0.0 RC 2 of Cake has been released. Take it for a spin and give us feedback on our discussion board.

This is the second (and likely last) pre-release of Cake 2.0🎉

See also:

In this blog post, we will go through what's new in Cake RC 2, compared to RC 1.

Highlights of this release

  • Added support for .NET v6.0.100 RTM
  • Improvements and bug fixes to the new dotnet aliases
  • Less noise on the logs by default when resolving assemblies
  • Improvements to IntelliSense support when using Visual Studio Code ... and more! The full list of changes is listed below.

Upgrading

See Upgrade instructions for documentation about breaking changes in this release.

Supported runners and required .NET version

To allow Cake to make use of modern platform features, make life easier for extension authors and simplify decision process of users we have decided to stop shipping Cake runner for .NET Framework and the already deprecated Cake runner for .NET Core with 2.0. Additionally we dropped support to run on .NET Core 2.1 and .NET Core 3.0 for Cake .NET Tool and Cake Frosting.

This means that, starting with Cake 2.0, you will need to have the .NET SDK installed on your build machine, at a minimum .NET Core 3.1, but .NET 6 is recommended, in order to run Cake. In other words, Cake itself will no longer run on .NET Framework, Mono and .NET Core 3.0 or older. Cake will continue to support building of .NET Framework projects as well as projects targeting .NET Core 3.0 or older.

Supported platform matrix for Cake 2.0 will look like this:

Runner .NET 6 .NET 5 .NET Core 3.1
Cake .NET Tool
Cake Frosting

As a consequence of no longer shipping Cake runner for .NET Framework we will also stop shipping the Cake.Portable Chocolatey package and Homebrew Cake formulae.

Cake runner for .NET Core has been deprecated since version 1.0 with Cake .NET Tool as the suggested replacement. For users of Cake runner for .NET Framework it is also suggested to switch to Cake .NET Tool and run builds on .NET Core 3.1 or newer. For users which rely on an extension, or other dependencies, which require .NET Framework or .NET Core 3.0 or older, suggestion is to stay on Cake 1.x.

See Sunsetting of .NET Framework and .NET Core runners in Cake 2.0 for details.

How can you help?

Help us by taking Cake 2.0 RC 2 for spin, test your scripts, addins and modules, if you have have questions please raise them on our GitHub Discussions and report any issues on our GitHub Issues.

Easiest and safest way to test is by using .NET Tool with a local tool manifest.

dotnet new tool-manifest
dotnet tool install Cake.Tool --version 2.0.0-rc0002

Then Cake will be available only in that folder where you created the manifest and not interfere with any other of your Cake projects.

dotnet cake build.cake

Contributors

This release was made possible thanks to the contribution of these awesome members of the Cake community along with the Cake team:

Issues

As part of this release we had 13 issues closed.

Breaking changes

  • #3714 Use Basic.Reference.Assemblies.* to ensure all standard reference assemblies are available for Roslyn (@devlead)

Improvements

  • #3709 Arguments alias should support ICollection as default value (@devlead)
  • #3691 Update Microsoft.NETCore.Platforms to 6.0.0 (@devlead)
  • #3690 Update Microsoft.Extensions.DependencyInjection to 6.0.0 (@devlead)
  • #3689 Update System.Reflection.Metadata to 6.0.0 (@devlead)
  • #3688 Update System.Collections.Immutable to 6.0.0 (@devlead)
  • #3681 ScriptAssemblyResolver logging should be at debug/diagnostic level (@gitfool)

Bug Fixes

  • #3711 SemanticVersion missing equals/not equals operator, prerelease sorted wrong (@devlead)
  • #3697 Error: The requested service 'Cake.Commands.DefaultCommandSettings' has not been registered (@augustoproiete)
  • #3693 Core suffix is still used in some settings classes (@augustoproiete)
  • #3683 Use DotNetMSBuildSettings instead of DotNetCoreMSBuildSettings on new dotnet aliases settings (@augustoproiete)
  • #3671 VS2022: msbuild can not be located, only Build Tools are installed (@augustoproiete)

Documentation

  • #3701 Add cake-module tag to Cake.DotNetTool.Module NuGet package (@augustoproiete)