git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: What does the 100 in R100 mean?

From
Thomas Rast <trast@student.ethz.ch>
Date
May 14, 2010, 12:20 UTC
Message-ID
<201005141420.52657.trast@student.ethz.ch>
In-Reply-To
<20100514112145.GQ12846@penguin.codegnome.org>
Todd A. Jacobs wrote:
Show 9 quoted lines
> When I'm looking at the output for renamed files in git-log or
> git-whatchanged, renamed files always seem to say "R100." So, I looked
> in the man page, followed the internal references to --diff-filter, and
> remain stumped as to what the digits stand for. I couldn't even find an
> explanatory comment in the git source code.
> 
> Obviously, R is for "(R)enamed." What is the "100" for? If it's being
> returned as a flag to --name-status and friends, it should probably be
> documented somewhere.
It is, but in the "wrong" section:
RAW OUTPUT FORMAT
[...]
       Possible status letters are:
       ·   A: addition of a file
       ·   C: copy of a file into a new one
       ·   D: deletion of a file
       ·   M: modification of the contents or mode of a file
       ·   R: renaming of a file
[...]
       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.

The patch below might rectify that, but it's not that reader-friendly because it has to point at the git-diff manpage where diff-format.txt is not included. The ifdef is also an incomplete test because diff-{files,index,tree} include diff-format.txt but don't set git-diff.

diff --git i/Documentation/diff-options.txt w/Documentation/diff-options.txt
index 98cc779..424971c 100644
--- i/Documentation/diff-options.txt
+++ w/Documentation/diff-options.txt
@@ -107,8 +107,12 @@ any of those replacements occurred.
 	Show only names of changed files.
 
 --name-status::
-	Show only names and status of changed files. See the description
-	of the `--diff-filter` option on what the status letters mean.
+	Show only names and status of changed files. See the "RAW
+	OUTPUT FORMAT" section
+ifndef::git-diff[]
+	in linkgit:git-diff[1]
+endif::git-diff[]
+	for what the status codes mean.
 
 --submodule[=<format>]::
 	Chose the output format for submodule differences. <format> can be one of
-- 
Thomas Rast
trast@{inf,student}.ethz.ch
Previous: Todd A. Jacobs
Message 2 of 2 in “What does the 100 in R100 mean?”
  1. Todd A. JacobsMay 14, 2010
  2. Thomas RastMay 14, 2010

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.