Some more "Raw output format" doc improvements#2304
Open
phil-blain wants to merge 3 commits into
Open
Conversation
In the "Raw output format" section, we start by mentioning that 'git diff-tree' prints the hashes of what is being compared. This is only true in --stdin mode, and is already mentioned in the description of '--stdin' in git-diff-tree.adoc. Remove this sentence such that we only focus on the common output between diff-tree, diff-index, diff-files and diff --raw. Signed-off-by: Philippe Blain <levraiphilippeblain@gmail.com>
Since 10637b8 (diff-files: -1/-2/-3 to diff against unmerged stage., 2005-11-29), for unmerged entries 'git diff-files' print both an "unmerged" line ('U'), as well as an "in-place edit" line ('M') comparing stage 2 (by default) with the working tree. The "Raw output format" documentation however mentions that all commands print a single line per changed file. Adjust diff-format.adoc to also mention this special case, for completeness. Signed-off-by: Philippe Blain <levraiphilippeblain@gmail.com>
…only In the "Raw output format" section, we mention that the 'mode' and 'sha1' for "src" and "dst" are 0* if "(creation|deletion) or unmerged". For unmerged entries, 'mode' and 'sha1' are in fact 0* only when we are looking at the index, i.e. on the left side for 'git diff-files' and on the right side for 'git diff-index --cached'. Be more precise by mentioning this, and while at it uniformize the wording of the "work tree out of sync with the index" case. Signed-off-by: Philippe Blain <levraiphilippeblain@gmail.com>
Contributor
Author
|
/submit |
|
Submitted as pull.2304.git.git.1778860091.gitgitgadget@gmail.com To fetch this version into To fetch this version to local tag |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Here are some small improvements to the "Raw output format" documentation that I noticed while working on another topic.