EVOLUTION-MANAGER
Edit File: terminalExecute.html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><title>R: Execute Command</title> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <link rel="stylesheet" type="text/css" href="R.css" /> </head><body> <table width="100%" summary="page for terminalExecute {rstudioapi}"><tr><td>terminalExecute {rstudioapi}</td><td style="text-align: right;">R Documentation</td></tr></table> <h2>Execute Command</h2> <h3>Description</h3> <p>Execute a command, showing results in the terminal pane. </p> <h3>Usage</h3> <pre> terminalExecute(command, workingDir = NULL, env = character(), show = TRUE) </pre> <h3>Arguments</h3> <table summary="R argblock"> <tr valign="top"><td><code>command</code></td> <td> <p>System command to be invoked, as a character string.</p> </td></tr> <tr valign="top"><td><code>workingDir</code></td> <td> <p>Working directory for command</p> </td></tr> <tr valign="top"><td><code>env</code></td> <td> <p>Vector of name=value strings to set environment variables</p> </td></tr> <tr valign="top"><td><code>show</code></td> <td> <p>If FALSE, terminal won't be brought to front</p> </td></tr> </table> <h3>Value</h3> <p>The terminal identifier as a character vector (<code>NULL</code> if unable to create the terminal). </p> <h3>Note</h3> <p>The <code>terminalExecute</code> function was added in version 1.1.350 of RStudio. </p> <h3>Examples</h3> <pre> ## Not run: termId <- rstudioapi::terminalExecute( command = 'echo $HELLO && echo $WORLD', workingDir = '/usr/local', env = c('HELLO=WORLD', 'WORLD=EARTH'), show = FALSE) while (is.null(rstudioapi::terminalExitCode(termId))) { Sys.sleep(0.1) } result <- terminalBuffer(termId) terminalKill(termId) print(result) ## End(Not run) </pre> <hr /><div style="text-align: center;">[Package <em>rstudioapi</em> version 0.11 <a href="00Index.html">Index</a>]</div> </body></html>