diff options
author | Matthieu Moy <Matthieu.Moy@imag.fr> | 2013-07-16 10:05:36 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2013-07-17 17:50:56 -0700 |
commit | d09cd15d19de23aca532a85f6d27a71b2baceb3f (patch) | |
tree | 83ba6d8aa00c4b0d7ae10500fa04cfaf1ee4d155 /diff.c | |
parent | 8ade9b140f099540bcdec5bcf660faaf05b5e3ee (diff) | |
download | git-d09cd15d19de23aca532a85f6d27a71b2baceb3f.tar.gz |
diff: allow --no-patch as synonym for -s
This follows the usual convention of having a --no-foo option to negate
--foo.
Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr>
Reviewed-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'diff.c')
-rw-r--r-- | diff.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -3540,7 +3540,7 @@ int diff_opt_parse(struct diff_options *options, const char **av, int ac) options->output_format |= DIFF_FORMAT_NAME; else if (!strcmp(arg, "--name-status")) options->output_format |= DIFF_FORMAT_NAME_STATUS; - else if (!strcmp(arg, "-s")) + else if (!strcmp(arg, "-s") || !strcmp(arg, "--no-patch")) options->output_format |= DIFF_FORMAT_NO_OUTPUT; else if (!prefixcmp(arg, "--stat")) /* --stat, --stat-width, --stat-name-width, or --stat-count */ |