Domino allows you to install internally developed custom R and Python packages stored in GitHub or GitHub Enterprise. For best performance, do this by creating a custom environment. However, if you do not want to create a custom environment or you are running a quick test or prototype, you can install these packages in of a Domino project.
Start by configuring git integration in your Domino projects.
If it doesn’t already exist, create a file named requirements.txt
in
the root directory of your project. Add the following line to
requirements.txt
:
-e /repos/<repo_name>
After requirements.txt
is in place, Domino will automatically
install the Python package every time a workspace or batch run starts
within the project.
If it doesn’t already exist, create a file named install.R
in the root directory of your project. Add the following line to install.R
:
devtools::install_local('/repos/<repo_name>')
For example, if you want to install ggplot2
from a Git repository,
your install.R
should look like:
After this `install.R is in place, enter a line at the beginning of your work within the project to install the project for your sessions.
source('install.R')