Skip to content

Latest commit

 

History

History
126 lines (65 loc) · 2.92 KB

ExecFunction.md

File metadata and controls

126 lines (65 loc) · 2.92 KB

nodejsscriptDocs


nodejsscript / s / ExecFunction

Interface: ExecFunction()

ExecFunction(command): ShellString

Executes the given command synchronously.

Parameters

command: string

The command to execute.

Returns

ShellString

Returns an object containing the return code and output as string.

ExecFunction(command, options): ShellString

Executes the given command synchronously.

Parameters

command: string

The command to execute.

options: ExecOptions & object

Silence and synchronous options.

Returns

ShellString

Returns an object containing the return code and output as string, or if {async: true} was passed, a ChildProcess.

ExecFunction(command, options): ChildProcess

Executes the given command asynchronously.

Parameters

command: string

The command to execute.

options: ExecOptions & object

Silence and synchronous options.

Returns

ChildProcess

Returns an object containing the return code and output as string, or if {async: true} was passed, a ChildProcess.

ExecFunction(command, options): ChildProcess | ShellString

Executes the given command.

Parameters

command: string

The command to execute.

options: ExecOptions

Silence and synchronous options.

Returns

ChildProcess | ShellString

Returns an object containing the return code and output as string, or if {async: true} was passed, a ChildProcess.

ExecFunction(command, options, callback): ChildProcess

Executes the given command synchronously.

Parameters

command: string

The command to execute.

options: ExecOptions

Silence and synchronous options.

callback: ExecCallback

Receives code and output asynchronously.

Returns

ChildProcess

ExecFunction(command, callback): ChildProcess

Executes the given command synchronously.

Parameters

command: string

The command to execute.

callback: ExecCallback

Receives code and output asynchronously.

Returns

ChildProcess