I like the idea of whitespace fixing in pre-commit, but I'd prefer if it only cleaned whitespace on the hunks that have changed, rather than on the entire file. Has anyone come up with a pre-commit version that does this?
threads / discuss / 16068
Per-hunk whitespace cleaning in pre-commit?
Subject: Per-hunk whitespace cleaning in pre-commit?