NpmRunScriptAliases.

NpmRunScript(ICakeContext, string, Action<NpmRunScriptSettings>) Method

Summary

Runs a npm script using the settings returned by a configurator.
Assembly
Cake.Npm.dll
Namespace
Cake.Npm
Containing Type
NpmRunScriptAliases

Syntax

public static void NpmRunScript(this ICakeContext context, string scriptName, Action<NpmRunScriptSettings> configurator)

Examples

Use specific log level

NpmRunScript("hello", settings => settings.WithLogLevel(NpmLogLevel.Verbose));

Attributes

Type Description
CakeMethodAliasAttribute
CakeAliasCategoryAttribute

Parameters

Name Type Description
context ICakeContext The context.
scriptName string Name of the script to execute as defined in package.json.
configurator Action<NpmRunScriptSettings> The settings configurator.

Return Value

Type Description
void