create_app {RInno} | R Documentation |
This function manages installation and app start up. To accept all defaults, just provide app_name
. After calling create_app
, call compile_iss
to create an installer in dir_out
.
create_app(app_name, app_dir = getwd(), dir_out = "RInno_installer", pkgs = c("jsonlite", "shiny", "magrittr"), repo = "http://cran.rstudio.com", locals = "none", remotes = "none", app_repo_url = "none", auth_user = "none", auth_pw = "none", auth_token = "none", user_browser = "chrome", include_R = FALSE, include_Pandoc = FALSE, include_Chrome = FALSE, include_Rtools = FALSE, R_version = paste0(">=", R.version$major, ".", R.version$minor), Pandoc_version = rmarkdown::pandoc_version(), Rtools_version = "3.5", overwrite = TRUE, ...)
app_name |
The name of the app. It will be displayed throughout the installer's window titles, wizard pages, and dialog boxes. See [Setup]:AppName for details. For continuous installations, |
app_dir |
Development app's directory, defaults to |
dir_out |
Installer's directory. A sub-directory of |
pkgs |
Character vector of package dependencies. To provide version limits, a named character vector with an inequality in front of the version number, |
repo |
Default repository to install CRAN package dependencies. Defaults to |
locals |
Character vector of local package dependencies. Supports package versions like |
remotes |
Character vector of GitHub repository addresses in the format |
app_repo_url |
Repository address for continuous installations in the format |
auth_user |
Bitbucket username. It is recommended to create a read-only account for each app. Support for OAuth 2 and tokens is in the works. |
auth_pw |
Bitbucket password matching the above username. |
auth_token |
To install from a private Github repo, generate a personal access token (PAT) in https://github.com/settings/tokens and supply to this argument. This is safer than using a password because you can easily delete a PAT without affecting any others. |
user_browser |
Character for the default browser. Options include "chrome", "firefox", and "ie." |
include_R |
To include R in the installer, |
include_Pandoc |
To include Pandoc in the installer, |
include_Chrome |
To include Chrome in the installer, |
include_Rtools |
To include Rtools in the installer, |
R_version |
R version to use. Supports inequalities similar to |
Pandoc_version |
Pandoc version to use, defaults to: |
Rtools_version |
Rtools version to include. For more information, see Building R for Windows. |
overwrite |
Logical. Should existing installation files be overwritten? See |
... |
Arguments passed on to |
Creates the following files in app_dir
:
Icons for installer and app, setup.ico and default.ico respectively.
Files that manage app start up, utils/package_manager.R, utils/ensure.R, and utils/app.R.
First/last page of the installer, infobefore.txt and infoafter.txt.
Batch support files, utils/wsf/run.wsf, utils/wsf/js/run.js, utils/wsf/js/json2.js, utils/wsf/js/JSON.minify.js.
A configuration file, config.cfg. See create_config
for details.
A batch file, app_name.bat. See create_bat
for details.
An Inno Setup Script, app_name.iss.
Jonathan M. Hill and Hanjo Odendaal
get_R
, copy_installation
, create_config
, create_bat
, directives_section
, setup_section
, languages_section
, tasks_section
, files_section
, icons_section
, run_section
, and code_section
.
## Not run: create_app('myapp') create_app( app_name = 'My AppName', app_dir = 'My/app/path', dir_out = 'wizard', pkgs = c('jsonlite', shiny = '1.0.5', magrittr = '1.5', 'xkcd'), locals = c('my_pkg'), include_R = TRUE, # Download R and install it with the app R_version = "2.2.1", # Old version of R privilege = 'high', # Admin only installation default_dir = 'pf') # Program Files ## End(Not run)