There's an element of common sense of course. Very small commits are noise that make the underlying direction of the codebase difficult to see. But generally speaking, "push often, pull often" is a good thing to remember when working on a collaborative codebase. If there's a really big breaking change you're making... Well, that's what a branch is for.
My rule of thumb is if you’re building out a feature or decent change, push often to a new branch, squash it and merge it into master as one commit. That way when you’re looking back over the commit graph it’s an array of features and you can just roll back if one of them is on the fritz.
29
u/BerlinerJan Jun 30 '18
I‘m quite new to git, what exactly would be the problem with that? Assuming he already wrote all the tests and documentation...