HandyControl/build/build.cake

72 lines
2.1 KiB
Plaintext
Raw Normal View History

2019-12-01 19:10:58 +08:00
var target = Argument("target", "Build");
Task("Clean")
.Does(() =>
{
CleanDirectory("lib");
});
Task("Build")
.IsDependentOn("Clean")
.Does(() =>
{
2020-05-23 23:00:11 +08:00
NuGetRestore("../src/HandyControl.sln");
2019-12-01 19:10:58 +08:00
2020-05-23 23:00:11 +08:00
var settingsNet40 = new DotNetCoreBuildSettings
2019-12-01 19:10:58 +08:00
{
Configuration = "Release",
2020-05-23 23:00:11 +08:00
OutputDirectory = "lib/net40"
};
2019-12-01 19:10:58 +08:00
2020-05-23 23:00:11 +08:00
var settingsNet45 = new DotNetCoreBuildSettings
2019-12-01 19:10:58 +08:00
{
2020-05-23 23:00:11 +08:00
Configuration = "Release",
Framework = "net45",
OutputDirectory = "lib/net45"
};
2019-12-01 19:10:58 +08:00
2020-05-23 23:00:11 +08:00
var settingsNet462 = new DotNetCoreBuildSettings
2019-12-01 19:10:58 +08:00
{
2020-05-23 23:00:11 +08:00
Configuration = "Release",
Framework = "net462",
OutputDirectory = "lib/net462"
};
2019-12-01 19:10:58 +08:00
2020-05-23 23:00:11 +08:00
var settingsNet47 = new DotNetCoreBuildSettings
2019-12-01 19:10:58 +08:00
{
2020-05-23 23:00:11 +08:00
Configuration = "Release",
Framework = "net47",
OutputDirectory = "lib/net47"
};
2019-12-01 19:10:58 +08:00
2020-05-23 23:00:11 +08:00
var settingsNet48 = new DotNetCoreBuildSettings
2019-12-01 19:10:58 +08:00
{
2020-05-23 23:00:11 +08:00
Configuration = "Release",
Framework = "net48",
OutputDirectory = "lib/net48"
};
2019-12-01 19:10:58 +08:00
var settingsCore30 = new DotNetCoreBuildSettings
{
2020-05-23 23:00:11 +08:00
Configuration = "Release",
2019-12-01 19:10:58 +08:00
Framework = "netcoreapp3.0",
OutputDirectory = "lib/netcoreapp3.0"
};
2020-02-29 12:47:32 +08:00
var settingsCore31 = new DotNetCoreBuildSettings
{
2020-05-23 23:00:11 +08:00
Configuration = "Release",
2020-02-29 12:47:32 +08:00
Framework = "netcoreapp3.1",
OutputDirectory = "lib/netcoreapp3.1"
};
2020-05-23 23:00:11 +08:00
DotNetCoreBuild("../src/Net_40/HandyControl_Net_40/HandyControl_Net_40.csproj", settingsNet40);
DotNetCoreBuild("../src/Net_GE45/HandyControl_Net_GE45/HandyControl_Net_GE45.csproj", settingsNet45);
DotNetCoreBuild("../src/Net_GE45/HandyControl_Net_GE45/HandyControl_Net_GE45.csproj", settingsNet462);
DotNetCoreBuild("../src/Net_GE45/HandyControl_Net_GE45/HandyControl_Net_GE45.csproj", settingsNet47);
DotNetCoreBuild("../src/Net_GE45/HandyControl_Net_GE45/HandyControl_Net_GE45.csproj", settingsNet48);
DotNetCoreBuild("../src/Net_GE45/HandyControl_Net_GE45/HandyControl_Net_GE45.csproj", settingsCore30);
DotNetCoreBuild("../src/Net_GE45/HandyControl_Net_GE45/HandyControl_Net_GE45.csproj", settingsCore31);
2019-12-01 19:10:58 +08:00
});
RunTarget(target);