git-diff-*: support "-u" as a synonym for "-p"
I'm probably not the only one whose fingers have gotten hard-wired to use "-u" for "unified diff".
This commit is contained in:
@ -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;
|
||||
}
|
||||
|
Reference in New Issue
Block a user