Skip to content

Commit

Permalink
Update to Cake Tool 5.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Kralizek committed Dec 10, 2024
1 parent 3da2719 commit 07a4a0e
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion .config/dotnet-tools.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"isRoot": true,
"tools": {
"cake.tool": {
"version": "1.1.0",
"version": "5.0.0",
"commands": [
"dotnet-cake"
],
Expand Down
18 changes: 9 additions & 9 deletions build.cake
Original file line number Diff line number Diff line change
Expand Up @@ -42,25 +42,25 @@ Task("Version")
Task("Restore")
.Does<BuildState>(state =>
{
var settings = new DotNetCoreRestoreSettings
var settings = new DotNetRestoreSettings
{

};

DotNetCoreRestore(state.Paths.SolutionFile.ToString(), settings);
DotNetRestore(state.Paths.SolutionFile.ToString(), settings);
});

Task("Build")
.IsDependentOn("Restore")
.Does<BuildState>(state =>
{
var settings = new DotNetCoreBuildSettings
var settings = new DotNetBuildSettings
{
Configuration = "Debug",
NoRestore = true
};

DotNetCoreBuild(state.Paths.SolutionFile.ToString(), settings);
DotNetBuild(state.Paths.SolutionFile.ToString(), settings);
});

Task("RunTests")
Expand Down Expand Up @@ -95,16 +95,16 @@ Task("RunTests")
.WithFilter("-:Tests*")
.WithFilter("-:TestUtils");

var settings = new DotNetCoreTestSettings
var settings = new DotNetTestSettings
{
NoBuild = true,
NoRestore = true,
Logger = $"trx;LogFileName={testResultFile.FullPath}",
Loggers = [$"trx;LogFileName={testResultFile.FullPath}"],
Filter = "TestCategory!=External",
Framework = framework
};

DotCoverCover(c => c.DotNetCoreTest(projectFile, settings), coverageResultFile, dotCoverSettings);
DotCoverCover(c => c.DotNetTest(projectFile, settings), coverageResultFile, dotCoverSettings);
}
catch (Exception ex)
{
Expand Down Expand Up @@ -190,7 +190,7 @@ Task("PackLibraries")
.IsDependentOn("Restore")
.Does<BuildState>(state =>
{
var settings = new DotNetCorePackSettings
var settings = new DotNetPackSettings
{
Configuration = "Release",
NoRestore = true,
Expand All @@ -199,7 +199,7 @@ Task("PackLibraries")
ArgumentCustomization = args => args.Append($"-p:SymbolPackageFormat=snupkg -p:Version={state.Version.PackageVersion}")
};

DotNetCorePack(state.Paths.SolutionFile.ToString(), settings);
DotNetPack(state.Paths.SolutionFile.ToString(), settings);
});

Task("Pack")
Expand Down

0 comments on commit 07a4a0e

Please sign in to comment.