3 ms·
Yes, rebase is awesome and every Git user should learn about it. But why not both? When I'm working on a more complex patch series, it's not uncommon for me to
by atq2119 5y ago
Yes, rebase is awesome and every Git user should learn about it. But why not both?
When I'm working on a more complex patch series, it's not uncommon for me to have a bunch of already cleaned up, or semi-cleaned up commits on top of the remote branch I'm working against, and then a bunch of random garbage "WIP" commits. Something that often happens is that I `git reset` not to the upstream branch but to my most recent clean commit, take the resulting changes apart into individual commits (often, some of them will be squash/fixup as I discovered a bug or missing piece of earlier work) and then `git rebase` with `rebase.autosquash` enabled in my global Git config.
- dljsjr 5y agoSure. I do that as well. But this article was advocating for using a soft reset to replicate what is ostensibly the built-in fixup mechanisms from interactive rebasing.