In DataSHIELD the development of a package leads to the generation of two packages. Nearly each function consists in fact of two complementary functions: one running on the remote server (behind the firewall of the data owner) and referred to as server side function and its counterpart running on the local computer or analysis centre (i.e. the computer the analyses are ran from) and referred to as client side function. Server side functions are in the server side package and client side functions are in the client side package as shown in the very simple graph below. |
The rest of this page shows how the server side package repository is initialized in GitHub but the client side package repository is created exactly the same way apart from the description section where we indicate that it is a server side package.
Horizontal DataSHIELD uses GitHub for distributed development (Read more about GitHub here or watch these videos). Hence the project is located in GitHub and packages are maintained there. The project name in GitHub is DataSHIELD
and it can be found online here. The package we are going to develop in this tutorial will also be located under the DataSHIELD
project.
In this tutorial we are going to build a package from scratch. The name of our package is |
Each new HDS package requires a new repository - each a HDS R package corresponds in fact to one GitHub repository. To create a new repository the coordinator or anyone with same rights goes to the project page and click on the button +New repository. A new page will then open up (see image below).
This is the strict responsibility of the project coordinator or someone with same privileges. Any developer can be given such rights but it is better to have a designated person for this task. The same person might be also responsible of the main branch , the |
Follow the instructions to below fill in the information required on the page:
DataSHIELD
.Naming of packages
).Public
.R
because we want an R package.GNU GPL v3.0
.This falls also under the responsibility of the project/package coordinator or someone with similar privileges as mentioned in the warning Who creates the new repository
.
Because only the coordinator is allowed to 'push' into the main branch all other developers should be allocated their own branches where their developments will takes place before - the final versions are merged with the master
branch periodically. To create a branch just click on the repository name (if not already open) and then click on branch:master as shown in the below image. The branch name should be the first letter of the developer' first name followed by his/her surname. If the name already exists use some variants (e.g insert middle name etc). Then click on Create branch: ... to finish. In the below example a branch is being created for the developer agaye
Now repeat the same above steps to create the client side package repository: the name of the repository should be dsTutorialClient
and in the description section write A client side package to illustrate the development of a Horizontal DataSHIELD R package
.