git add -p to commit only the lines that belong together
A file with a bug fix and an unrelated rename in it makes one bad commit or two lazy ones. Patch mode lets you stage hunk by hunk.
git add -p
# y stage, n skip, s split the hunk, e edit it by handReviewers get a commit that says one thing. You get a diff you can revert without losing the other change.
git