Documentation changes to recursive option for git-diff-tree
Update docs and usages regarding '-r' recursive option for git-diff-tree. Remove '-r' from common diff options, mention it only for git-diff-tree. Remove one extraneous use of '-r' with git-diff-files in get-merge.sh. Sync the synopsis and usage string for git-diff-tree. Signed-off-by: Chris Shoemaker <c.shoemaker at cox.net> Signed-off-by: Junio C Hamano <junkio@cox.net>
Chris Shoemaker committed
Oct 28, 2005 at 13:04 UTC
50b8e355b64c93a71d5008557e15f52c032240ff
4 files changed
+9
-5
Documentation/git-diff-tree.txt
+4
-1
@@ -8,7 +8,7 @@ git-diff-tree - Compares the content and mode of blobs found via two tree object
8
9
SYNOPSIS
10
--------
11
-'git-diff-tree' [--stdin] [-m] [-s] [-v] [--pretty] [-t] [<common diff options>] <tree-ish> [<tree-ish>] [<path>...]
11
+'git-diff-tree' [--stdin] [-m] [-s] [-v] [--pretty] [-t] [-r] [--root] [<common diff options>] <tree-ish> [<tree-ish>] [<path>...]
12
13
DESCRIPTION
14
-----------
@@ -33,6 +33,9 @@ include::diff-options.txt[]
33
Note that this parameter does not provide any wildcard or regexp
34
features.
35
36
+-r::
37
+ recurse into sub-trees
38
+
39
-t::
40
show tree entry itself as well as subtrees. Implies -r.
41
diff-tree.c
+4
-2
@@ -149,8 +149,10 @@ static int diff_tree_stdin(char *line)
149
}
150
151
static const char diff_tree_usage[] =
152
-"git-diff-tree [--stdin] [-m] [-s] [-v] [--pretty] [-t] "
153
-"[<common diff options>] <tree-ish> <tree-ish>"
152
+"git-diff-tree [--stdin] [-m] [-s] [-v] [--pretty] [-t] [-r] [--root] "
153
+"[<common diff options>] <tree-ish> [<tree-ish>] [<path>...]\n"
154
+" -r diff recursively\n"
155
+" --root include the initial commit as diff against /dev/null\n"
156
COMMON_DIFF_OPTIONS_HELP;
157
158
int main(int argc, const char **argv)
diff.h
-1
@@ -91,7 +91,6 @@ extern void diffcore_std_no_resolve(struct diff_options *);
91
92
#define COMMON_DIFF_OPTIONS_HELP \
93
"\ncommon diff options:\n" \
94
-" -r diff recursively (only meaningful in diff-tree)\n" \
94
" -z output diff-raw with lines terminated with NUL.\n" \
95
" -p output patch format.\n" \
96
" -u synonym for -p.\n" \
git-merge.sh
+1
-1
@@ -25,7 +25,7 @@ dropsave() {
25
26
savestate() {
27
# Stash away any local modifications.
28
- git-diff-index -r -z --name-only $head |
28
+ git-diff-index -z --name-only $head |
29
cpio -0 -o >"$GIT_DIR/MERGE_SAVE"
30
}
31