-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.cake
64 lines (55 loc) · 1.96 KB
/
build.cake
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
#region ScriptImports
// Scripts
#load "CakeScripts/base/base.buildsystem.cake"
#load "CakeScripts/base/base.variables.cake"
#load "CakeScripts/base/base.setup.cake"
#load "CakeScripts/base/base.nuget.restore.cake"
#load "CakeScripts/base/base.msbuild.cake"
#load "CakeScripts/base/base.coverlet.tool.cake"
#load "CakeScripts/base/base.coveralls.upload.cake"
#load "CakeScripts/base/base.gitreleasenotes.cake"
#load "custom.nuget.pack.cake"
#load "CakeScripts/base/base.nuget.push.cake"
#load "CakeScripts/base/base.docfx.cake"
#load "CakeScripts/base/base.sonarqube.cake"
#endregion
#region Tasks
// Set up variables specific for the project
Task ("VariableSetup")
.Does(() => {
projectName = "VaraniumSharp.WinUI";
releaseFolderString = "./{0}/bin/{1}/net8.0-windows10.0.19041.0";
releaseBinaryType = "dll";
repoOwner = "NinetailLabs";
botName = "NinetailLabsBot";
botEmail = "[email protected]";
botToken = EnvironmentVariable("BotToken");
gitRepo = string.Format("https://github.com/{0}/{1}.git", repoOwner, projectName);
sonarQubeKey = "NinetailLabs_VaraniumSharp.WinUI";
sonarBranch = branch;
sonarOrganization = "ninetaillabs";
sonarQubeServerUrl = "https://sonarcloud.io";
sonarLogin = EnvironmentVariable("SonarToken");
excludedFiles = new List<string> { "**/System.Text.Json.SourceGeneration/**/*.g.cs" };
toolVersion = MSBuildToolVersion.VS2022;
});
Task ("Default")
.IsDependentOn ("DiscoverBuildDetails")
.IsDependentOn ("OutputVariables")
.IsDependentOn ("LocateFiles")
.IsDependentOn ("VariableSetup")
.IsDependentOn ("NugetRestore")
.IsDependentOn ("SonarQubeStartup")
.IsDependentOn ("Build")
.IsDependentOn ("UnitTests")
.IsDependentOn ("SonarQubeShutdown")
.IsDependentOn ("CoverageUpload")
// .IsDependentOn ("GenerateReleaseNotes")
.IsDependentOn ("NugetPack")
.IsDependentOn ("NugetPush")
//.IsDependentOn ("Documentation")
.IsDependentOn ("FailBuildIfTestFailed");
#endregion
#region RunTarget
RunTarget (target);
#endregion