DownloadToolAliases.

DownloadTool(ICakeContext, string) Method

Summary

Installs the tool described by a complete download: directive (the text #tool takes), unless an identical install is already there, and registers its files with context.Tools.

Syntax

public static IReadOnlyCollection<FilePath> DownloadTool(this ICakeContext context, string directive)

Examples

Task("Report").Does(() =>
{
    DownloadTool("download:https://github.com/jqlang/jq/releases/download/jq-{version}/jq-{os}-{arch}{exe}?package=jq&version=1.8.2&os.darwin=macos&checksums=sha256sum.txt&checksums_sha256=dc86824a41c165ece971ff691aff6e08bbfe6e1d1f531688b47ee78c283a85cd");
});

Attributes

Type Description
CakeMethodAliasAttribute

Parameters

Name Type Description
context ICakeContext The Cake context.
directive string The directive, starting with download:.

Return Value

Type Description
IReadOnlyCollection<FilePath> The registered files.