Skip to content
This repository has been archived by the owner on Aug 30, 2023. It is now read-only.

Set the MSBuild optimize property to true #226

Merged
merged 2 commits into from Mar 11, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
14 changes: 10 additions & 4 deletions build.cake
Expand Up @@ -110,20 +110,26 @@ Task("Build")
var settings = new MSBuildSettings
{
Configuration = configuration + "-" + framework,
ToolVersion = MSBuildToolVersion.VS2017,
ToolVersion = MSBuildToolVersion.VS2017
};
settings.WithProperty("TargetFramework", new string[] { framework });

settings.WithProperty("TargetFramework", new string[] { framework })
.WithProperty("Optimize", new string[] { "true" });

MSBuild(solution, settings);
}

foreach (var framework in dotnetFrameworks)
{
DotNetCoreBuild(solution, new DotNetCoreBuildSettings
var settings = new DotNetCoreBuildSettings
{
Framework = framework,
Configuration = configuration + "-" + framework,
});
MSBuildSettings = new DotNetCoreMSBuildSettings()
.WithProperty("Optimize", new string[] { "true" })
};

DotNetCoreBuild(solution, settings);
}
});

Expand Down