Joint Effort for Data assimilation Integration Practical Merging

  • Slides: 4
Download presentation
Joint Effort for Data assimilation Integration Practical: Merging your feature branch into the develop

Joint Effort for Data assimilation Integration Practical: Merging your feature branch into the develop branch Joint Center for Satellite Data Assimilation (JCSDA) JEDI Academy – 06 June 2018

Three basic steps • Issue a pull request – Make sure you set the

Three basic steps • Issue a pull request – Make sure you set the “base” branch to develop – Assign people to review your changes – Associate with an issue • Code review – Comments, request to change code, approval • Merge – Admin of repository will merge in your code

Some things to keep in mind • Our policy is that you must merge

Some things to keep in mind • Our policy is that you must merge the develop branch into your feature branch before you issue a pull request – Any conflicts between your feature branch and develop are resolved in this step – In your local copy • • • git remote update –p git checkout develop git pull origin develop git checkout feature/my-changes git merge develop – If there are conflicts: • Warnings are issued with some instructions – The files with conflicts are listed • The merge is suspended – Git tracks this action • The files with conflicts are marked inside showing you contents of the develop branch adjacent to the contents of your feature branch • Edit the files and use the marks to decide how to resolve the conflict • Issue another commit after conflicts are resolved, push that commit and then issue the pull request

Some things to keep in mind (cont. ) • Pick reviewers that are impacted

Some things to keep in mind (cont. ) • Pick reviewers that are impacted by your changes or are familiar with the repository that you are requesting the change – Code review is a complementary method, to testing, that helps with finding defects in the code • The merge will advance the github repository (remote) forward past your local repository, and your feature branch will have been deleted from the remote repository – Sync your local copy right after the merge occurs • • git remote update –p git checkout develop git pull origin develop git branch –d feature/my-changes # may need –D option