domino.runCommand: domino.runCommand

Description Usage Arguments Examples

View source: R/domino.runCommand.R

Description

Runs domino client command and runs success callback or shows failure message

Usage

1
2
domino.runCommand(commandAndArgs, successCallback = domino.OK,
failureMessage = "Executing the command failed", stdInput = FALSE)

Arguments

commandAndArgs

The commandAndArgs argument is a string that matches standard domino client's syntax,ex. "get quick-start" or "download".

successCallback

A function that will be called when domino command executes successfuly. Defaults to noop function.

failureMessage

A string representing failure message that should be printed when command fails. Has default value.

stdInput

Internal string data that is pushed to domino client's stdio streams. Default is no stdio stream input.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
## Not run: 
success <- function() {
print("Success!")
}
domino.runCommand("run main.R 1 2 3",success, "failed to succeed")
# Runs command "run main.R 1 2 3" and 
# calls 'success' function if domino command ends successfuly.
# Prints error message  - "failed to succeed" if domino command fails.

## End(Not run)

domino documentation built on May 2, 2019, 10:16 a.m.