Re: git-diff/git-diff-files: Turn off copy-detection?
- From
Johannes Sixt <j.sixt@viscovery.net>
- Date
- Sep 29, 2009, 13:40 UTC
- Message-ID
- <4AC20E37.3090204@viscovery.net>
- In-Reply-To
- <4AC20286.6020108@gmail.com>
Marius Storm-Olsen schrieb:
Show 15 quoted lines
> I'm trying to diff the header files between two version of a repo, to do > an ABI review, but get too many diffs from 'similar copy', which makes > the review hard. These are generally unrelated files, but due to large > copyright header, and spaces, the actual changes are not large enough to > be detected as new files. I'd therefore like to turn off copy detection > completely, or at least set some kind of threshold before a file is > considered a copy in the diff. > > Doing a 'git diff origin/4.5..origin/4.6 -- src/corelib' gives me this > excerpt: > > diff --git origin/4.5/src/corelib/tools/qtimeline.h > origin/4.6/src/corelib/animation/qabstractanimation.h > similarity index 58% > ...
You must have the config variable diff.renames set. But I would not expect that this setting applies to 'git diff-files', only to 'git diff'.
You can also try 'git diff -C99 -M99' if you don't want to unset the config variable.
-- Hannes