forked from danm-de/pcsc-sharp
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.fsx
56 lines (44 loc) · 1.17 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
#load ".fake/build.fsx/intellisense.fsx"
open Fake.Core
open Fake.DotNet
open Fake.DotNet.NuGet
open Fake.IO
open Fake.IO.FileSystemOperators
open Fake.IO.Globbing.Operators
open Fake.Core.TargetOperators
Target.create "Clean" (fun _ ->
!! "src/**/bin"
++ "src/**/obj"
++ "Tests/**/bin"
++ "Tests/**/obj"
|> Shell.cleanDirs
)
Target.create "Build" (fun _ ->
!! "src/**/*.*proj"
++ "Tests/**/*.*proj"
|> Seq.iter (DotNet.build id)
)
Target.create "Test" (fun _ ->
!! "Tests/**/*.*proj"
|> Seq.iter (DotNet.test id)
)
Target.create "NuGetPush" (fun _ ->
let setNugetPushParams (defaults:NuGet.NuGetPushParams) =
{ defaults with
Source = Some "https://api.nuget.org/v3/index.json"
}
let setParams (defaults:DotNet.NuGetPushOptions) =
{ defaults with
PushParams = setNugetPushParams defaults.PushParams
}
!! "src/**/bin/Release/*.nupkg"
|> Seq.iter (fun file -> DotNet.nugetPush setParams file)
)
Target.create "All" ignore
"Clean"
==> "Build"
==> "Test"
==> "All"
"Build"
==> "NuGetPush"
Target.runOrDefault "All"