Git flow for working on svn branch
The Problem: you want to play on git code branches on svn server. Here’s the simple flow.
1. Specify the layout when running git svn clone:
Specify the trunk, branch and tags by -T,-b,-t, such as: -T dev -b branches -t tags
2. To fetch all updates of all svn server branches:
git svn fetch
When you run git svn fetch, all branches will be updated, and new branches on the remote will be added. git svn fetch fetches the updates with out modifying the local working files (while git svn rebase would).
3. To show all branches include server branches:
git branch -r
4. To switch to work on a server branch: server-branch-v2.8
git checkout -b local-v2.8 server-branch-v2.8 then working on the local-2.8 branch, and commit, dcommit, your changes would be dcommitted to the server branch.