aboutsummaryrefslogtreecommitdiff
path: root/Documentation/diff-options.txt
diff options
context:
space:
mode:
authorBjörn Gustavsson <bgustavsson@gmail.com>2009-11-22 20:43:20 +0100
committerJunio C Hamano <gitster@pobox.com>2009-11-22 12:08:00 -0800
commit64485b4aba98b39f2cf4528aed95b6ddca62f332 (patch)
treec7fff38d377f34d00cba6a20eed17e528c506624 /Documentation/diff-options.txt
parent39add7a36feca434ba85267cb76e4fd69bcdc13a (diff)
downloadgit-64485b4aba98b39f2cf4528aed95b6ddca62f332.tar.gz
git-64485b4aba98b39f2cf4528aed95b6ddca62f332.tar.xz
Clarify and correct -z
The description for -z is too vague and general for the apply, diff*, and log commands. Change the description of -z for 'git log' to note that commits will be separated by NULs. Change the description of -z for 'git diff*' and 'git apply' to note that it applies to the --numstat option, and for 'git diff*' also for --raw option. Also correct the description of the "munging" of pathanmes that takes place in the absence of -z for the 'git diff*' and 'git apply' commands, namely that apart from the characters mentioned, double quotes will also be escaped and that the pathname will be enclosed in double quotes if any characters are escaped. Signed-off-by: Björn Gustavsson <bgustavsson@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Documentation/diff-options.txt')
-rw-r--r--Documentation/diff-options.txt17
1 files changed, 14 insertions, 3 deletions
diff --git a/Documentation/diff-options.txt b/Documentation/diff-options.txt
index 2b37193a3..18366b1be 100644
--- a/Documentation/diff-options.txt
+++ b/Documentation/diff-options.txt
@@ -85,10 +85,21 @@ ifndef::git-format-patch[]
endif::git-format-patch[]
ifndef::git-format-patch[]
+
-z::
- NUL-line termination on output. This affects the `--raw`
- output field terminator. Also output from commands such
- as `git-log` will be delimited with NUL between commits.
+ifndef::git-log[]
+ When `--raw` or `--numstat` has been given, do not munge
+ pathnames and use NULs as output field terminators.
++
+Without this option, each pathname output will have TAB, LF, double quotes,
+and backslash characters replaced with `\t`, `\n`, `\"`, and `\\`,
+respectively, and the pathname will be enclosed in double quotes if
+any of those replacements occurred.
+endif::git-log[]
+
+ifdef::git-log[]
+ Separate the commits with NULs instead of with new newlines.
+endif::git-log[]
--name-only::
Show only names of changed files.