1. What is rebase develop?
(1)Before rebase develop
(2)Rebase process
(3)After rebase
(4)After squash
Work done(got money)! Simple is beautiful
2. What is merge develop?
(1) Before merge
(2) Merge process
### (3) After merge
### (4) Merge to develop
> Work done(got money)! Not elegant? absolutely
## 3. How to avoid conflict?
### (1) When commit count = 1 rebase develop is simple
> Like merge develop. Only one conflict at most.
> If commits multiple times, it means you will solve conflict many times,
> But the total amount of work is the same as merge develop.
### (2) DO NOT use merge and rebase together
> It means you will solve every commit conflict in develop
### (3) After rebase
> Use “ git push origin --set-upstream YOUR_BRANCH_NAME ”
> If you already push your local branch to origin
> Use “ git push -f ” (force) to cover origin/YOUR_BRANCH
## 4. When to use rebase and merge?
> If you are developing multiple features on a single branch at the same time, and each individual feature is committed only once(important commit), you can use merge develop in this case,but only once when you are ready to merge.
> If you do multiple commits, but they are basically the same function(not important commit), you should use rebase
Powerd by http://mind.pipers.cn/