3 ms·
Someone will correct me, hopefully, if I'm wrong: Rebase means moving the branch point of your feature branch to later on the main branch. Let's say you creat
by bloopernova 5y ago
Someone will correct me, hopefully, if I'm wrong:
Rebase means moving the branch point of your feature branch to later on the main branch.
Let's say you create feature branch foo from main on 2021-08-01. You do work. Others do work and add them to main. On 2021-09-18, you rebase foo onto main. This has the effect of re-writing history! There's no longer a branch point at 08-01, it's been moved to 09-18.
https://www.atlassian.com/git/tutorials/merging-vs-rebasing https://www.atlassian.com/git/tutorials/merging-vs-rebasing
Rebase is not always the best option. I personally prefer merging, and that has worked for 100% of situations I've found myself in so far in my DevOps career.
- Izkata 5y ago> Someone will correct me, hopefully, if I'm wrong: > Rebase means moving the branch point of your feature branch to later on the main branch. It refers to a more generic action/set of actions, where this description is one possible end result. Granted this is probably the most common use, and the name "re-base" definitely fits this usage best. The more generic action is something like "take a set of commits in one place in the git history, and reapply them somewhere else in the git history, optionally dropping or rearranging some of them in the process".
- bloopernova 5y agoIt's strangely wonderful to me that people can have so many different ways of explaining this action/concept. Your description is definitely more accurate than mine :)