Re: Score in diff-format
- From
Michael J Gruber <git@drmicha.warpmail.net>
- Date
- Jan 28, 2015, 14:32 UTC
- Message-ID
- <54C8F306.1000001@drmicha.warpmail.net>
- In-Reply-To
- <20150128062309.GA29506@glandium.org>
Mike Hommey schrieb am 28.01.2015 um 07:23:
Show 24 quoted lines
> Hi, > > diff-format.txt says this: > > An output line is formatted this way: > (snip) > > That is, from the left to the right: > > (snip) > . status, followed by optional "score" number. > > (snip) > Status letters C and R are always followed by a score (denoting the > percentage of similarity between the source and target of the move or > copy), and are the only ones to be so. > > As I read this last paragraph, the following is not supposed to happen: > $ git diff-tree 926b1ec63ee045503f609e88ca445b94c06bd5d7 --abbrev -r -C -B > 926b1ec63ee045503f609e88ca445b94c06bd5d7 > :100644 100644 81ac702... 7ab0cf4... M087 contrib/subtree/INSTALL > > It however makes sense that it happens, and it looks like a case of the > documentation being outdated or confusing. Or am I interpreting it wrong?
I'd say it depends on the definition of "so". The documentation is correct if you read "so" as "*always* followed by a score". I guess you read it as "followed by a score".
Percentages with M are not mentioned in diff-format, but they are a consequence of "-B" processing. Maybe we could mention that?
Michael