This document has information about how to manage branches in grouper. Assumes using Eclipse.
Standards
Example branch name: GROUPER_1_6_BRANCH
Example branch merge point: just commit the misc/merge.txt
How do I work in a branch?
You need to checkout that branch from SVN, and work in it. Here is how:
- You should probably close all projects of different branches since the names will conflict. Or you can rename with the branch in the name (e.g. grouper_trunk)
- If you have the branch checked out, just import the project into eclipse, or open the project
- If not, then:
- Go to the SVN Repositories perspective
- Go to branches and the branch name
- Do not work in a tag (i.e. do not commit to a tag), only work in trunk or a branch
Which branch should I work in, and when? How to merge?
If you are making a change for the next major release (or before a branch has been made for a release), use trunk
If you are making a fix for a previous branch, then (instructions for subclipse eclipse SVN plugin):
- Make the change in the oldest branch first (see instructions above)
- Commit the change (and keep loose track of which files were touched)
- Open the second-most-recent branch, and sync. Then right click and click Team->Merge
- Merge a range of revisions
- Uncheck "Perform pre-merge best practices check"
- Merge from, put the older branch (e.g. GROUPER_1_2_BRANCH)
- Select revisions on next page
- Select all revisions since the last merge from that branch to this branch (see in comments)
- You will see a synchronization of all files changed, and merge them all forward (even if not your changes, though you can communicate with who made those changes if you like)
- This means in the sync, get all the latest changes, figure out the conflicts, etc. Get the changes from the right to the left of the sync window
- Make sure you have merged all the changes
- Generally launch the graphical editor for diffs
- Sync and commit the newer branch (e.g. GROUPER_1_3_BRANCH or HEAD).
- Make a change to the grouper/misc/merge.txt to indicate that a merge occurred in the past branch
- Now if the branch you merged to is not trunk, then merge that forward to all most recent branches with the same technique until you are merged to trunk