-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathSpec.fs
More file actions
64 lines (57 loc) · 1.57 KB
/
Spec.fs
File metadata and controls
64 lines (57 loc) · 1.57 KB
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
module Spec
open Fake.Core
open EasyBuild.FileSystemProvider
module Files =
type Root = AbsoluteFileSystem<__SOURCE_DIRECTORY__>
module Ops =
[<Literal>]
let Prelude = "Prelude"
[<Literal>]
let Clean = "Clean"
[<Literal>]
let GitNet = "GitNet"
[<Literal>]
let RestoreTools = "RestoreTools"
[<Literal>]
let Build = "Build"
[<Literal>]
let Pack = "Pack"
[<Literal>]
let GitPush = "GitPush"
[<Literal>]
let Publish = "Publish"
[<Literal>]
let PublishLocal = "PublishLocal"
// [<Literal>]
// let Test = "Test"
// [<Literal>]
// let Format = "Format"
// [<Literal>]
// let CheckFormat = "CheckFormat"
module Args =
let mutable apiKey: string option = None
let mutable local: bool = false
let mutable parallelise: bool = false
let setArgs args =
let containsArg arg =
args |> Array.contains arg
let getArgValue arg =
args
|> Array.tryFindIndex ((=) arg)
|> Option.map ((+) 1)
|> Option.bind(fun idx ->
Array.tryItem idx args
)
parallelise <- containsArg "--parallel"
apiKey <- getArgValue "--nuget-api-key"
local <- containsArg "--local"
open Fake.IO.Globbing.Operators
let sourceFiles =
!! "**/*.fs"
-- "packages/**/*.*"
-- "paket-files/**/*.*"
-- ".fake/**/*.*"
-- "**/obj/**/*.*"
-- "**/AssemblyInfo.fs"
let githubUsername = "GitHub Action"
let githubEmail = "41898282+github-actions[bot]@users.noreply.github.com"