2 ms·
"It's sometimes astonishing how the pursuit of optimal diffs masks the intent of a change where an added method diff starts with the closing brace of the previo
by aptwebapps 14y ago
"It's sometimes astonishing how the pursuit of optimal diffs masks the intent of a change where an added method diff starts with the closing brace of the previous method, for example."
In Python you can get the whole return statement. Especially when adding a similar type of method, e.g.: Django view functions. Makes
git add -p
more fun.
- mpyne 14y agoI've found that experimenting with the various git diff algorithms helps out. IIRC there is an "-x patience" flag you can pass to git-diff and tools which use that, which spends more time to get "better" diffs.