"FAKE.Dotnet" is FAKE build automation system extension for .NET Core CLI tools. It contains helpers to download and install specific versions .NET Core SDK with CLI. Currently supports only windows.
See the API documentation for all available helpers and Release Notes for version details
.NET Core SDK is downloaded and installed using dotnet-install.ps1 powershell script. By default SDK is installed to %LOCALAPPDATA%\Microsoft\dotnet
folder (and version subfolders).
There is sample project and build script for 1.0.1 SDK tooling
#r "tools/FAKE.Dotnet/tools/Fake.Dotnet.dll" // include Fake.Dotnet lib
open Fake.Dotnet
Target "Initialize" (fun _ ->
DotnetSdkInstall SdkVersions.NetCore101
)
Target "BuildProjects" (fun _ ->
let solutionFile = "solution.sln"
DotnetRestore id solutionFile
DotnetPack (fun c ->
{ c with
Configuration = Debug;
VersionSuffix = Some "ci-100";
OutputPath = Some (currentDirectory @@ "artifacts")
}) solutionFile
)
"Initialize" // define the dependencies
==> "BuildProjects"
Run "BuildProjects"