For users on version 1.47 or later, you can add Git repositories to a Domino project.
These repositories are made available to your runs and workspace sessions allowing you to access them just as you would your Domino files. This article explains how you can add your repository to the project, access the added repository from within a workspace and finally, commit any changes back to the git repository.
Domino supports HTTPS and SSH URIs, and bot public and private repositories. For private repositories, follow these instructions to set up your Git credentials.
Adding a repository to a project
Git repositories are added at the project level, and you can add multiple repositories to one project. You can follow along in the video below.
Specifying your branch
Domino allows you to connect to a specific git reference. For most users, they'll want to connect to the default branch which, with Github, will be the master unless set otherwise in Github; however, you can also specify a specific branch, tag or commit ID to use. This might be useful for someone who want to use their own branch of the repo or who had a tag specifying a version number, for example.
Accessing your repository
Once you've added your repository to your project, it will be mounted in a subfolder of
/repos each time you perform a run so you can access the files as needed.
If you edit the files in your git repository from your run, don't forget to
git push your changes to your external repository. Domino will automatically warn you if you attempt to close a workspace session without committing your changes back to your repository.
In RStudio, you can access your repository through the files pane. Your Domino project files will will be in
/mnt as normal, and now, a copy of your Git repository will be in a subfolder of the
/repos folder. You can browse to the
/repos folder by clicking the root (
/) path in the RStudio Files pane.
If you edit or add files in your repository, you can manually push and commit them back to github by using the Shell.
Once in Shell, you should navigate to your git repository and then use your standard git commands.
Jupyter Notebook Instructions
In a Jupyter notebook, you can open a terminal session, navigate to your repository and then perform your standard git commands.
Keywords: Git, Github, Bitbucket