DEV Community

Discussion on: The Git Rebase Introduction I Wish I'd Had

Collapse
 
shayd16 profile image
Shayne Darren • Edited

I worked on a repo where one branch was used per project and all commits for all features were made to that branch, the process here was you commit your changes and then run a:

git pull --rebase

I have a basic understanding that this does the same thing as mentioned in the above article, except instead of the latest commit of another branch, this applies your commits to the latest commit on your branch, is this accurate or is there much more going on under the hood that I am not aware of?

Collapse
 
unixnut profile image
Alastair Irvine

I think this works like it "hides" all your commits since the last common one, does the pull, then reapplies all your commits (with different IDs) onto the last pulled commit.