Nbgitpuller lets you share the contents of a git repository with other users and have them open the contents of the repo inside their JupyterLab environment. This can be especially useful if you plan on sharing some codebase with multiple students (homework, assignments, code examples etc.).
Once the link is clicked, contents of the repository are opened in a Jupyter instance of the user.
Nbgitpuller then tries to keep the contents of the shared projects in sync with the git repository by automatically updating file that were modified in the repo, and keeping the user’s changes when there are conflicts. See here or below for details.
Using Nbgitpuller's link generator, you can specify the URL of your git repository, the file or directory that should be opened when the link is accessed, and whether the repo should be opened in JupyterLab, or some other type of application.
The developers also provide a Firefox or Chrome extension (the latter should also work on Microsoft Edge)

'1. Go to nbgitpuller’s link generator'

'2. Specify the URL of the Jupyter Hub that will be used. For University of Twente’s Jupyter this is https://jupyter.utwente.nl '

'3. Specify the URL of the GIT repository you intend to share and the branch to pull from.'

* Make sure your repository is set to 'public' beforehand.
* If your repository has been created recently (after 2020) you may need to set the branch to main instead of master

'4. Specify the file or directory from your repository that will be opened when the user clicks the link. '

'5. Specify the application in which the project should be opened.'

*NOTE: When using UTwente’s Hub, only the Classic Jupyter Notebook or JupyterLab options will work. To use other applications (such as RStudio, PyCharm, MatLab etc.) you must specify a 'Custom URL'

'(Optional) Specify the name of the Jupyter server to be used. Not needed unless your partners or students to work on a specific server'

Once a user has clicked on a link, nbgitpuller will make a best effort to keep the user up to date with the contents of the git repository. If you modify, add or remove a file in the repository, unless the user has modified the same file at the same line of code, the changes will be reflected in the user's project. See here for a detailed explanation of what could happen in different edit scenarios.

Detailed documentation for nbgitpuller can be found here