curate | R Documentation |
Helper function to manage package installation across libraries
curate( pkg, repos = "https://packagemanager.rstudio.com/all/__linux__/xenial/latest", version = NULL, dest_lib = .libPaths()[1], git_provider = NULL, ... )
pkg |
String, name of package to install or a valid URL if using GitHub/Gitlab |
version |
The desired version of the package to install. Defaults to latest. |
dest_lib |
String, the path to the library where packages will be installed. Default is the first path on ‘.libPaths()'. It’s recommended to use 'set_library()' prior to 'curate()' |
git_provider |
String, one of "github" or "gitlab". Default is NULL. |
... |
Additional arguments to be passed to 'install.packages', 'remotes::install_version', 'remotes::install_github', and 'remotes::install_gitlab'. Use this to pass authentication variables to git providers. |
repo |
Where to pull the package from. Default is RStudio Package Manager (https://packagemanager.rstudio.com/all/__linux__/xenial/latest). If NULL, specify the path to a source file in 'pkgs'. |
'curate()' lets you easily install packages into different libraries. It will manage the copying of packages to a path on DBFS, which will persist them from session to session on Databricks.
The user library path
# Setting user library first set_library("/dbfs/rk/my_packages") curate(pkg = "broom") # Install version, setting user library curate(pkg = "broom", version = "0.4.2", lib = set_library("/dbfs/rk/my_old_packages")) # Install GitHub curate(repo = "RafiKurlansik/bricksteR") # Install Gitlab curate(repo = "jimhester/covr")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.