-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.fsx
52 lines (42 loc) · 1.07 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
#r "paket:
nuget FSharp.Core 5
nuget Fake.DotNet.Cli
nuget Fake.IO.FileSystem
nuget Fake.Core.Target
nuget Fake.Core.Trace
nuget Fake.DotNet.Testing.XUnit2 //"
#load ".fake/build.fsx/intellisense.fsx"
open Fake.Core
open Fake.DotNet
open Fake.DotNet.Testing
open Fake.IO
open Fake.IO.FileSystemOperators
open Fake.IO.Globbing.Operators
open Fake.Core.TargetOperators
let buildDir = "./build/"
Target.create "Clean" (fun _ ->
!! "./src/**/bin/"
++ "./src/**/obj/"
++ "./test/**/bin/"
++ "./test/**/obj/"
|> Shell.cleanDirs
)
// Default Target
Target.create "Default" (fun _ ->
Trace.trace "Hello World from FAKE"
)
Target.create "Build" (fun _ ->
!! "./src/**/*.csproj"
++ "./test/**/*.csproj"
|> Seq.iter (DotNet.build id)
)
Target.create "Test" (fun _ ->
!! "./test/**/bin/**/test.dll"
|> XUnit2.run (fun p ->
{p with
HtmlOutputPath = Some("./tmp/TestOutput/" @@ "html") })
)
"Clean"
==> "Build"
==> "Test"
Target.runOrDefault "Default"