We are going through the use of datalad for synchronising the repositories on your desktop and on the GIN server.

Setting up

Install datalad

Refer to http://handbook.datalad.org/en/latest/intro/installation.html

Provide SSH key

To provide a ssh key, you may follow this tutorial: https://docs.github.com/en/authentication/connecting-to-github-with-ssh/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent Personally, I prefer to use Rstudio to create and use keys: https://support.posit.co/hc/en-us/articles/200532077-Version-Control-with-Git-and-SVN

In GIN, you need to add one key: click on your avatar on the top right corner of this page, choode your settings. Choose the SSH Keys vertical tab, then click the blue add Key button. Give it a name of your choice, and paste the public key text in the Contentsection.

Download your repository

  • Go to your .mainrepository and paste the ssh address you get. Its form should be similar to ssh://git@gindata.biologie.hu-berlin.de:10022/organame/projectname.main.git
  • open a command prompt/terminal widow, you may try to right click on a folder to open the terminal inside that specified folder
  • write datalad clone
  • paste the ssh address you copied before
  • type return

The repository should be cloned at that point. This means that the content of the main repository will be downloaded on your local machine.

Synchronisation Using scripts

We provide scripts you can double-click to synchronise all respositories.

  • windows user: double click sync.bat, it will run the datalad script.
  • OSX, Linux user: Firs make sync_unix executable (need to be done once), then double click sync_unix

To make the file executable run chmod +x datalad-unix in a terminal window opened in the repository (you may need to navigate using the cdcommand).

Iamabot edited this page 1 year ago