This page prepares new developers to work on the R Synapse Client.
Retrieve the code base from Github
Create an account for yourself at https://github.com/.
Go to the central repository for the Synapse R Client: https://github.com/Sage-Bionetworks/rSynapseClient
"Fork" the repository, making a copy under your own Github account.
Now clone the repository to your local machine, creating two remotes, "upstream" is the central repo', while "origin" refers to your fork. You will pull code from upstream (the central repo) and push changes to origin. (TODO add a triangle diagram.)
Configure Eclipse (optional)
At Sage Bionetworks we use Eclipse as our IDE. Use the statET plug-in for R support.
Get some work to do
The open work items (bugs and new features) are tracked in JIRA under the SYNR project:
Create a feature branch
On your local machine make sure you have the latest version of the code base:
git checkout develop
git pull upstream develop
Now create a feature branch, named after the JIRA issue you're working on, e.g. for issue SYNR-1234:
git checkout
b SYNR1234
Build the Client and run the test suite
Once you've made changes it's time to build the client and run the test suite. There are two ways to build:
- tools/prebuild.sh
- R CMD install .
or
- tools/build.sh
Now start up R and run the test suite:
library(synapseClient) synapseClient:::.test() synapseLogin() synapseClient:::.integrationTest()
Push your code changes to Github
git push origin SYNR-1234
In github, create a pull request, from the feature branch in your fork to the develop branch in the central one.
Get a code reivew and ask the reviewer to accept your pull request, merging your code into the central repo.
A continuous build system is triggered by the merge event. It checks out the head of the 'develop' branch and runs the sames test suites that you ran locally, ensuring your changes are compatible with other changes that have been checked in.