Title: | R Console Bindings for the 'Domino Command-Line Client' |
---|---|
Description: | A wrapper on top of the 'Domino Command-Line Client'. It lets you run 'Domino' commands (e.g., "run", "upload", "download") directly from your R environment. Under the hood, it uses R's system function to run the 'Domino' executable, which must be installed as a prerequisite. 'Domino' is a service that makes it easy to run your code on scalable hardware, with integrated version control and collaboration features designed for analytical workflows (see <http://www.dominodatalab.com> for more information). |
Authors: | Jacek Glodek <[email protected]> |
Maintainer: | Nick Elprin <[email protected]> |
License: | MIT + file LICENSE |
Version: | 0.3.1 |
Built: | 2024-11-13 05:44:05 UTC |
Source: | https://github.com/cran/domino |
The Domino R package is a wrapper on top of the Domino command-line client. It lets you run Domino commands (e.g., "run", "upload", "download") directly from your R environment. Under the hood, it uses R's system function to run the Domino executable, which must be installed as a prerequisite.
Package: domino
Type: Package
Version: 0.2-7
Date: 2015-05-27
License: MIT
Author: Jacek Glodek [email protected]
Maintainer: Nick Elprin [email protected]
Domino Data Lab support webpage - http://help.dominodatalab.com/
## Not run: ## logins as a given user to the Domino server ## and approves sending error reports to Domino. domino.login("jglodek", "MySecretPassword", TRUE) ## creates new project. domino.create("my-new-project") ## gets existing project from the server. domino.get("jglodek/my-old-project") ## gets existing project from the server. domino.get("my-old-project") ## initializes new domino project in current working directory with a given name. domino.init("other-name") ## downloads run results from Domino server. domino.download() ## uploads project files to Domino server. domino.upload() ## runs main.r in the cloud with given arguments. domino.run("main.r", "other", "console", "arguments") ## shows difference between current version and last uploaded version. domino.diff() ## displays current run's status in the console. domino.status() ## shows debug information domino.debug() ## resets project defined in by current working directory domino.reset() ## runs any of domino client command with given arguments domino.runCommand("run my-file.r", successCallback, "failure message!") ## End(Not run)
## Not run: ## logins as a given user to the Domino server ## and approves sending error reports to Domino. domino.login("jglodek", "MySecretPassword", TRUE) ## creates new project. domino.create("my-new-project") ## gets existing project from the server. domino.get("jglodek/my-old-project") ## gets existing project from the server. domino.get("my-old-project") ## initializes new domino project in current working directory with a given name. domino.init("other-name") ## downloads run results from Domino server. domino.download() ## uploads project files to Domino server. domino.upload() ## runs main.r in the cloud with given arguments. domino.run("main.r", "other", "console", "arguments") ## shows difference between current version and last uploaded version. domino.diff() ## displays current run's status in the console. domino.status() ## shows debug information domino.debug() ## resets project defined in by current working directory domino.reset() ## runs any of domino client command with given arguments domino.runCommand("run my-file.r", successCallback, "failure message!") ## End(Not run)
Creates Domino project. Changes working directory to new project's one.
domino.create(projectName)
domino.create(projectName)
projectName |
String that will be the name of the new project. |
## Not run: # in directory ./ domino.create("my-new-project") # current working directory is now switched to ./my-new-project and new project is initialized. ## End(Not run)
## Not run: # in directory ./ domino.create("my-new-project") # current working directory is now switched to ./my-new-project and new project is initialized. ## End(Not run)
Shows changes between your local version of project's data, and the version uploaded to the Domino servers.
domino.diff()
domino.diff()
Downloads the latest Domino run results to the project's folder.
domino.download()
domino.download()
Downloads given project data from Domino. Changes working directory to the project's directory.
# Usage without username domino.get("projectName")
# Usage without username domino.get("projectName")
projectName |
String containing project name. It can be prefixed by
username and slash. Ex. |
## Not run: # in directory ./ domino.get("my-project-in-the-cloud") # current working directory is now switched to ./my-project-in-the-cloud and the directory # is filled with files from Domino server. # The name of the project is prepended with username domino.get("jglodek/my-project-in-the-cloud") ## End(Not run)
## Not run: # in directory ./ domino.get("my-project-in-the-cloud") # current working directory is now switched to ./my-project-in-the-cloud and the directory # is filled with files from Domino server. # The name of the project is prepended with username domino.get("jglodek/my-project-in-the-cloud") ## End(Not run)
Initializes new domino project in current directory. It can also set arbitrary name to the project, even if different from current directory name.
# inits a project inside current directory, with given name. # ex. if run in ~/my_project, with "my_name" as a param, # it will create a Domino project called my-param inside ~/my_project directory. domino.init("projectName")
# inits a project inside current directory, with given name. # ex. if run in ~/my_project, with "my_name" as a param, # it will create a Domino project called my-param inside ~/my_project directory. domino.init("projectName")
projectName |
Project name for the project that will be created in current working directory. |
## Not run: # in directory ./ domino.init("my-new-project") # new project with name "my-new-project" is initialized inside current directory. ## End(Not run)
## Not run: # in directory ./ domino.init("my-new-project") # new project with name "my-new-project" is initialized inside current directory. ## End(Not run)
Logins to Domino server.
domino.login(usernameOrEmail, password, approvalForSendingErrorReports=FALSE, host)
domino.login(usernameOrEmail, password, approvalForSendingErrorReports=FALSE, host)
usernameOrEmail |
Login or e-mail address used when registering for
Domino Data Lab account. Ex. |
password |
Secret password that was set for authenticating in Domino
Data Lab server. If the password is not provided,a password prompt will be
shown for interactive sessions. For non-interactive sessions, this arguments
is required. Ex. |
approvalForSendingErrorReports |
Approval for the Domino client to send
error reports to Domino in order to improve the product
(these will NEVER include any of your data or source code).
This defaults to FALSE. Ex. |
host |
The location of the domino server (this argument is optional)
Ex. |
## Not run: domino.login("jglodek", TRUE) domino.login("jglodek","my-super-secret-password", TRUE) domino.login("jglodek","my-super-secret-password", TRUE, "https://app.dominodatalab.com") ## End(Not run)
## Not run: domino.login("jglodek", TRUE) domino.login("jglodek","my-super-secret-password", TRUE) domino.login("jglodek","my-super-secret-password", TRUE, "https://app.dominodatalab.com") ## End(Not run)
Runs your project on Domino servers with given parameters.
domino.run(..., publishApiEndpoint=FALSE)
domino.run(..., publishApiEndpoint=FALSE)
... |
All the run arguments will be joined together using space character.
Ex. |
publishApiEndpoint |
Whether or not to republish the project's API endpoint at the end of the run. |
## Not run: my_data <- 4 domino.run("main.R","1","my-file1.csv", my_data) #=> Runs "domino main.R 1 my-file1.csv 4" ## End(Not run)
## Not run: my_data <- 4 domino.run("main.R","1","my-file1.csv", my_data) #=> Runs "domino main.R 1 my-file1.csv 4" ## End(Not run)
Runs domino client command and runs success callback or shows failure message
domino.runCommand(commandAndArgs, successCallback = domino.OK, failureMessage = "Executing the command failed", stdInput = FALSE)
domino.runCommand(commandAndArgs, successCallback = domino.OK, failureMessage = "Executing the command failed", stdInput = FALSE)
commandAndArgs |
The |
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. |
## 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)
## 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)
take a snapshot of your command history and workspace.
domino.snapshot(commitMessage)
domino.snapshot(commitMessage)
commitMessage |
A committ message to record with you snapshot |
Shows status of current Domino project.
domino.status(...)
domino.status(...)
... |
Arguments normally passed to the domino status command. |
Synchronizes the local project copy with the server project copy, by running 'download' followed by 'upload'.
domino.sync()
domino.sync()
Uploads local version of Domino project files to the server.
domino.upload(commitMessage)
domino.upload(commitMessage)
commitMessage |
Commit message for Domino client, explaining changes you
did to the project code in recent update. Ex. |