summaryrefslogtreecommitdiff
path: root/diff-cache.c
diff options
context:
space:
mode:
Diffstat (limited to 'diff-cache.c')
-rw-r--r--diff-cache.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/diff-cache.c b/diff-cache.c
index 603a6b7..33b3b31 100644
--- a/diff-cache.c
+++ b/diff-cache.c
@@ -193,7 +193,8 @@ int main(int argc, const char **argv)
/* We accept the -r flag just to look like git-diff-tree */
continue;
}
- if (!strcmp(arg, "-p")) {
+ /* We accept the -u flag as a synonym for "-p" */
+ if (!strcmp(arg, "-p") || !strcmp(arg, "-u")) {
diff_output_format = DIFF_FORMAT_PATCH;
continue;
}