1
0
mirror of https://github.com/osmarks/random-stuff synced 2024-11-08 13:39:53 +00:00
random-stuff/KerbalName/build.fsx

52 lines
997 B
Plaintext
Raw Normal View History

2020-08-12 19:31:12 +00:00
// include Fake libs
#r "./packages/FAKE/tools/FakeLib.dll"
open Fake
// Directories
let buildDir = "./build/"
let deployDir = "./deploy/"
// Filesets
let appReferences =
!! "/**/*.csproj"
++ "/**/*.fsproj"
// version info
let version = "1.2a"
// Targets
Target "Clean" (fun _ ->
CleanDirs [buildDir; deployDir]
)
Target "Build" (fun _ ->
MSBuildDebug buildDir "Build" appReferences
|> Log "AppBuild-Output: "
)
Target "BuildRelease" (fun _ ->
MSBuildRelease buildDir "Build" appReferences
|> Log "AppBuild-Output: "
)
Target "Deploy" (fun _ ->
// Copy name data to buildDir for deployment
FileUtils.cp_r "KerbalNameData" (buildDir + "KerbalNameData/")
!! (buildDir + "/**/*.*")
-- "*.zip"
|> Zip buildDir (deployDir + "KerbalName." + version + ".zip")
)
// Build order
"Clean"
==> "BuildRelease"
==> "Deploy"
"Build" <=> "BuildRelease"
// start build
RunTargetOrDefault "Build"