generated from wazzamatazz/csharp-repo-template
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.cake
73 lines (67 loc) · 3.03 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
65
66
67
68
69
70
71
72
73
///////////////////////////////////////////////////////////////////////////////////////////////////
// Use build.ps1 or build.sh to run the build script. Command line arguments are documented below.
///////////////////////////////////////////////////////////////////////////////////////////////////
const string DefaultSolutionFile = "./JsonTimeSeriesExtractor.sln";
const string VersionFile = "./build/version.json";
///////////////////////////////////////////////////////////////////////////////////////////////////
// COMMAND LINE ARGUMENTS:
//
// --project=<PROJECT OR SOLUTION>
// The MSBuild project or solution to build.
// Default: see DefaultSolutionFile constant above.
//
// --target=<TARGET>
// The Cake target to run.
// Default: Test
// Possible Values: Clean, Restore, Build, Test, Pack, BillOfMaterials
//
// --configuration=<CONFIGURATION>
// The MSBuild configuration to use.
// Default: Release for Pack and BillOfMaterials targets; otherwise, Debug
//
// --clean
// Specifies that this is a rebuild rather than an incremental build. All artifact, bin, and test
// output folders will be cleaned prior to running the specified target.
//
// --no-tests
// Specifies that unit tests should be skipped, even if a target that depends on the Test target
// is specified.
//
// --ci
// Forces continuous integration build mode. Not required if the build is being run by a
// supported continuous integration build system.
//
// --sign-output
// Tells MSBuild that signing is required by setting the 'SignOutput' build property to 'True'.
// The signing implementation must be supplied by MSBuild.
//
// --build-counter=<COUNTER>
// The build counter. This is used when generating version numbers for the build.
//
// --build-metadata=<METADATA>
// Additional build metadata that will be included in the informational version number generated
// for compiled assemblies.
//
// --property=<PROPERTY>
// Specifies an additional property to pass to MSBuild during Build and Pack targets. The value
// must be specified using a '<NAME>=<VALUE>' format e.g. --property="NoWarn=CS1591". This
// argument can be specified multiple times.
//
// --github-username=<USERNAME>
// Specifies the GitHub username to use when making authenticated API calls to GitHub while
// running the BillOfMaterials target. You must specify the --github-token argument as well when
// specifying this argument.
//
// --github-token=<PERSONAL ACCESS TOKEN>
// Specifies the GitHub personal access token to use when making authenticated API calls to
// GitHub while running the BillOfMaterials target. You must specify the --github-username
// argument as well when specifying this argument.
//
///////////////////////////////////////////////////////////////////////////////////////////////////
#load nuget:?package=Jaahas.Cake.Extensions&version=2.1.0
// Bootstrap build context and tasks.
Bootstrap(DefaultSolutionFile, VersionFile);
// Get the target that was specified.
var target = GetTarget();
// Run the target.
RunTarget(target);