- Building Enterprise JavaScript Applications
- Daniel Li
- 73字
- 2021-07-23 16:31:02
Keeping our history clean
The reason our Git history looks so complicated is because git merge creates a separate commit for the merge. This is good because it doesn't alter the history of any of the branches; in other words, it is non-destructive:
To prevent the complicated history tree we have here, Git provides an alternative command, rebase, that allows us to merge changes, as well as keep our history clean.