Rebasing, Amend, and Cherry-Picking
If you say "rebasing" to most novice Git programmers, they burst into tears and run screaming from the room. But the truth is that this is only because of how it is explained in so many books and magazines, where rebasing is (correctly but confusingly) shown with diagrams of commits being copied and moved along with dense and technical text.
In truth, rebasing is not hard to understand, and it is not hard to do if you understand what it is for. In this chapter, we will review rebasing without fear.
Rebasing is a command that allows you to take a feature branch and place it on the tip of another branch. We'll discuss how, and more importantly why, you would do this.
Amending is a quick command that allows you to modify the most recent commit. You can use this to add a file you forgot to put in the commit or to fix up a botched message.
Cherry-picking is the ability to take one or more commits from a branch and apply...