You use rebase -i to get rid of "Oops fix comment" ''Oops fix indentation" "Oops fix small name" and put all these small fixups into the change that they are associated with, which keeps the history cleaner.
Yes, but only if you haven't pushed those commits upstream yet. If you already pushed commits with small errors, it's tough luck and you'll have to use the "oops small fix" commits.
Not sure what that is. What I usually do is commit to a remote branch, and before merging that branch into master, I tidy it up locally if there were any dirty commits in there.
That's fine if you can justifiably skip a post-rebase review.
force-with-lease, which is a recent addition, is force with seatbelts: it accepts a push if and only if the remote ref is where you think it is, preventing the case of overwriting history you are not aware of.
8
u/[deleted] Jun 19 '15
Yes, but only if you haven't pushed those commits upstream yet. If you already pushed commits with small errors, it's tough luck and you'll have to use the "oops small fix" commits.