Skip to content

Collaboration Workflow

John DiMatteo edited this page Dec 5, 2013 · 27 revisions

open_source_collaboration_workflow.png

Example Hello World github usage

Bar will update hello.py, and Foo will code review it.

  1. issue created with objective
  2. issue assignee creates feature branch or fork from master (branch preferred)
  3. objective completed in branch
    • clone the branch
$ git clone -b greet-user https://github.com/FooBar11112222/HelloWorld.git
* develop code, pushing regularly to branch
$ git commit -a -m "Added name prompt, for #1"
$ git push
    * note that if you [mention](https://github.com/blog/957-introducing-issue-mentions) the issue number followed by a # in the commit message like above, a comment will automatically be added to the issue with a link to the commit
* add test plan, verify test plan passing
* ![TestPlanAdded.png](http://jdimatteo.github.io/images/TestPlanAdded.png)
* ideally also add automated test so that it will continue to automatically be tested in the future (e.g. a diff test, like [the Bam_Liquidator_Bin_Counter_Test Jenkins test](http://tod.dfci.harvard.edu/jenkins/job/Bam_Liquidator_Bin_Counter_Test/), which runs automatically on every commit, and verifies that the counts have not changed since a prior run's calculated counts for a specific bam file)
  1. merge request created
    • click the green "Compare & review" button
    • PullRequestButton.png
    • click the "Click to create a pull request for this comparison" header button
    • CreatePullRequestHeaderButton.png
    • Update the pull request as you see fit, then click the "Send pull request" button
    • SendPullRequestButton.png
  2. peer code review (code reviewer or other peer also verifies testing passes, e.g. by adding comment "test passes")
  3. assignee responds to peer comments (usually with further commits, and re-syncing with master if significant time elapsing), repeat prior step
  4. assignee merges branch with master when code reviewer gives the go ahead (e.g. with a comment "merge it")
  5. Jenkins GUI wrapper jobs (and anything else using master) automatically uses updated master

Objectives

  • stable and usable master branch
  • code review and testing so that master branch code is understandable and of high quality
  • someone other than original developer verifying test plan passes
  • as simple a a process as could possibly work (with the understanding that it can be made more complicated as needed)

Prior Drafts

  • initial diagram, more complicated than current draft, with stable master but named release branch for a dedicated testing phase: open_source_collaboration_workflow_with_release_phase.png

References

Clone this wiki locally