Cake v6.0.0 released

Published
Tuesday, 11 November 2025
Category
Release Notes
Author
devlead

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

This release includes new features, improvements and bug fixes to Cake Scripting, Cake Frosting, and the new Cake.Sdk runner since the Cake v5.1.0 release! 🚀 🍰

Highlights of this release

  • .NET 10 support & C# 14 support
  • New runner: Cake.Sdk
  • Cake.Template
  • Addin recommended Cake version set to 6.0.0

.NET 10 support & C# 14 support

Cake now fully supports running on .NET 10, and with this C# 14, which means you can take advantage of the latest framework, runtime, and language improvements.

The supported platform matrix for Cake 6.0.0 will look like this:

Runner .NET 10 .NET 9 .NET 8
Cake .NET Tool
Cake Frosting
Cake.Sdk

New runner: Cake.Sdk

We're excited to announce Cake.Sdk as a new official runner for Cake! Cake.Sdk provides a modern way to get the Cake tool scripting experience in regular .NET console applications. This brings you the stellar experience of the new "dotnet run app.cs" feature (requires .NET 10), while also working seamlessly with .NET 8 and 9 for regular csproj projects.

Here's the minimal example:

#:sdk Cake.Sdk

Information("Hello world!");
dotnet cake.cs

Cake.Sdk is a custom SDK that provides a convenient way to create Cake projects with minimal configuration. It automatically sets up common properties and provides a streamlined development experience for Cake-based build automation projects, whether you're using the new file-based approach or traditional project-based builds.

Key features include:

  • Minimal Project Configuration: Create Cake projects with just a few lines in your .csproj file
  • File-based Build Scripts: Use the new #:sdk Cake.Sdk directive for standalone .cs files
  • Optimized Build Settings: Pre-configured with optimal settings for Cake projects
  • Built-in Source Generation: Includes Cake.Generator by default for automatic source generation capabilities
  • Full Cake Addin & Module Support: All existing Cake addins and modules work seamlessly
  • Native .NET CLI Publish Support: Create self-contained precompiled binaries and containers

Cake.Template

The easiest way to get started with Cake.Sdk is using the Cake.Template package, which provides several templates for different scenarios:

First, install the template package:

dotnet new install Cake.Template

Create a new Cake file-based project:

dotnet new cakefile --name cake

For the simplest possible setup, you can use the minimal template:

dotnet new cakeminimal --name cake

For larger projects, you can organize your code across multiple files:

dotnet new cakemultifile --name cake

For traditional project-based approach:

dotnet new cakeproj --Framework net10.0 --name cake

We've now set the recommended version of Cake.Core for addins to target to 6.0.0.

This won't break the build, but you might see warnings like the one below when addins or modules are loaded.

The assembly 'Cake.Addin, Version=5.0.0.0, Culture=neutral, PublicKeyToken=null'
is referencing an older version of Cake.Core (5.0.0).
For best compatibility it should target Cake.Core version 6.0.0.

The recommended target framework monikers for addins are now:

  • net10.0
  • net9.0
  • net8.0

Contributors

This release was made possible thanks to the Cake team and the contribution of these awesome members of the Cake community listed below:

Full details of everything that was included in this release can be seen below.

Issues

As part of this release we had 38 issues closed.

Breaking change

  • #4639 Make CakeSpectreReportPrinter the default ICakeReportPrinter.
  • #4638 Update Spectre.Console to 0.53.0.
  • #4593 Update LatestPotentialBreakingChange to 6.0.0.
  • #4534 Azure Pipleines Environement Agent Info uses FilePath instead of DirectoryPath.

Feature

  • #4592 C# 14 Scripting Support.
  • #4576 Add .NET 10 (net10.0) TFM.

Improvement

  • #4642 Display Delegated/Executed status as Succeded in Cake task summary.
  • #4636 Enhance file system abstraction with timestamps, Unix modes, and performance improvements.
  • #4627 .NET Test Platform Requires --project <PROJECT_PATH> / --solution <SOLUTION_PATH> to be specified.
  • #4624 Update System.* to 9.0.10.
  • #4623 Update Microsoft.Extensions.DependencyInjection to 9.0.10.
  • #4622 Update Spectre.Console to 0.52.0.
  • #4616 Replace using with await using for IAsyncDisposable resources.
  • #4615 Replace manual null checks with ArgumentNullException.ThrowIfNull().
  • #4614 Modernize Enum.GetName calls to use generic overload.
  • #4613 Use char literals instead of string literals for single characters in StreamWriter.Write.
  • #4612 Replace StringBuilder.Append(string.Join()) with StringBuilder.AppendJoin() for better performance.
  • #4611 Use char literals instead of string literals for single characters in StringBuilder.Append.
  • #4610 Replace string.Join with string.Concat for empty separator cases.
  • #4609 Optimize string.Join calls to use char separators instead of string separators.
  • #4608 Modernize dictionary access patterns with TryGetValue and deconstruction.

Bug

  • #4603 Fix .NET framework version detection.