This repository has been archived by the owner on Jun 23, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 5
/
build.fsx
98 lines (77 loc) · 3.19 KB
/
build.fsx
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
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
// --------------------------------------------------------------------------------------
// FAKE build script
// --------------------------------------------------------------------------------------
#r @"tools\FAKE\tools\FakeLib.dll"
open Fake
open Fake.AssemblyInfoFile
// --------------------------------------------------------------------------------------
// Information about the project to be used at NuGet and in AssemblyInfo files
// --------------------------------------------------------------------------------------
let project = "SeaMist"
let authors = ["Kevin Bronsdijk"]
let summary = "SeaMist a .NET library for the Kraken.io REST API"
let version = "0.1.1.8"
let description = "The SeaMist library interacts with the Kraken.io REST API allowing you to utilize Krakens features using a .NET interface."
let notes = "Includes Image Sets basics. For more information and documentation, please visit the project site on GitHub."
let nugetVersion = "1.1.8"
let tags = "kraken.io C# API image optimization"
let gitHome = "https://github.com/Kevin-Bronsdijk"
let gitName = "SeaMist"
// --------------------------------------------------------------------------------------
// Build script
// --------------------------------------------------------------------------------------
let buildDir = "./output/"
let packagingOutputPath = "./nuGet/"
let packagingWorkingDir = "./inputNuget/"
let nugetDependencies = getDependencies "./src/SeaMist/packages.config"
// --------------------------------------------------------------------------------------
Target "Clean" (fun _ ->
CleanDir buildDir
)
// --------------------------------------------------------------------------------------
Target "AssemblyInfo" (fun _ ->
let attributes =
[
Attribute.Title project
Attribute.Product project
Attribute.Description summary
Attribute.Version version
Attribute.FileVersion version
]
CreateCSharpAssemblyInfo "src/SeaMist/Properties/AssemblyInfo.cs" attributes
)
// --------------------------------------------------------------------------------------
Target "Build" (fun _ ->
!! "src/*.sln"
|> MSBuildRelease buildDir "Build"
|> Log "AppBuild-Output: "
)
// --------------------------------------------------------------------------------------
Target "CreatePackage" (fun _ ->
CreateDir packagingWorkingDir
CleanDir packagingWorkingDir
CopyFile packagingWorkingDir "./output/SeaMist.dll"
NuGet (fun p ->
{p with
Authors = authors
Dependencies = nugetDependencies
Files = [@"SeaMist.dll", Some @"lib/net452", None]
Project = project
Description = description
OutputPath = packagingOutputPath
Summary = summary
WorkingDir = packagingWorkingDir
Version = nugetVersion
ReleaseNotes = notes
Publish = false })
"scanr.nuspec"
DeleteDir packagingWorkingDir
)
// --------------------------------------------------------------------------------------
Target "All" DoNothing
"Clean"
==> "AssemblyInfo"
==> "Build"
==> "CreatePackage"
==> "All"
RunTargetOrDefault "All"