What is the recommended way to synchronize a git repo with upstream?
Let's say my work is based of SVN branch A in upstream. They have moved to branch B, and C. I want to 开发者_如何学Csynchronize my work with upstream now. Should I merge, pull, rebase, cherry pick?
What is the recommended way to create a clean patch against upstream?
Should I just diff? Or should I rebase and then squash?
You should use git-svn and get branch B and C.
If you want your work on top of B or C, rebase on top of those.
git checkout branchA
git rebase --onto branchB origin/BranchA # replace branchB with branchC if you want
What do you mean by "clean" patch against upstream?
You should rebase. It's up to you if you want to squash.
精彩评论