-
Notifications
You must be signed in to change notification settings - Fork 4
Home
Oleg edited this page May 16, 2018
·
10 revisions
Xake is MAKE clone, with an F# programming language as script language. Xake utilizes full power of the F# language to provide clean syntax:
#r "paket:
nuget Xake ~> 1.1 prerelease
nuget Xake.Dotnet ~> 1.1 prerelease //"
#if !FAKE
#load ".fake/project-example.fsx/intellisense.fsx"
#endif
open Xake
open Xake.Tasks
open Xake.Dotnet
let srcPath = "project-example-src"
do xakeScript {
rules [
"main" <== ["out/hw.exe"]
"out/hw.dll" ..> csc {src (!! "util.cs" @@ srcPath)}
"out/hw.exe" ..> csc {
target TargetType.Exe
src (!! "hw.cs" ++ "ver.cs" @@ srcPath)
ref !! "out/hw.dll"
}
srcPath </> "ver.cs" ..> recipe {
let! envver = getVar "VER"
let ver = envver |> Option.defaultValue "v0.1"
do! trace Message "Updating version number to `%s`" ver
do! writeText (sprintf """// static class App {const string Ver = "%s";}""" ver)
}
]
}
Unlike many other tools it was made with declarative approach in mind. Such approach allows to internally track dependencies which in turn brings extra benefits such as:
- incremental build (only rebuild affected part)
- estimate build time (progress indicator)
- execute tasks in parallel
>> Next >> Introduction
- Creating simple script
- Running the first build
- What the rule and recipe is?
- Filesets defined
- Editing the script
- Configure your project and CI
- Defining filesets
- Recipe computation
- Declaring the rules
- Error handling and exceptions
- Script and environment settings
- Command line interface (CLI)
- Writing cross-platform scripts
- Build-in functions
- .NET tasks
- System tasks
- Other
- ...