diff options
author | Junio C Hamano <junkio@cox.net> | 2007-01-17 14:32:52 -0800 |
---|---|---|
committer | Junio C Hamano <junkio@cox.net> | 2007-01-17 23:48:20 -0800 |
commit | e47f306d4bf964def1a0b29e8f7cea419471dffd (patch) | |
tree | 6ab4697911f1ee7051ac60f28d4bcbe46a37b884 | |
parent | Add --summary to git-format-patch by default (diff) | |
download | tgif-e47f306d4bf964def1a0b29e8f7cea419471dffd.tar.xz |
git-format-patch: make --binary on by default
It does not make much sense to generate a patch that cannot be
applied. If --text is specified on the command line it still
takes precedence.
Signed-off-by: Junio C Hamano <junkio@cox.net>
-rw-r--r-- | builtin-log.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/builtin-log.c b/builtin-log.c index c32a1df0bb..930cc0401c 100644 --- a/builtin-log.c +++ b/builtin-log.c @@ -470,6 +470,9 @@ int cmd_format_patch(int argc, const char **argv, const char *prefix) if (!rev.diffopt.output_format) rev.diffopt.output_format = DIFF_FORMAT_DIFFSTAT | DIFF_FORMAT_SUMMARY | DIFF_FORMAT_PATCH; + if (!rev.diffopt.text) + rev.diffopt.binary = 1; + if (!output_directory) output_directory = prefix; |