summaryrefslogtreecommitdiff
path: root/revision.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2019-04-09 17:14:23 (GMT)
committerJunio C Hamano <gitster@pobox.com>2019-04-09 17:14:23 (GMT)
commit31df2c1019733ac22fc848aa2658a0e25af70a79 (patch)
treec4924fdd7bc01bbf9a1027a340110286b9a45b13 /revision.c
parentac9e40e8ef796e43ae4438cbcd923bfa1056be61 (diff)
parent05314efaeaa0ae7cb0aa26d6347eabfe7cd8fc43 (diff)
downloadgit-31df2c1019733ac22fc848aa2658a0e25af70a79.zip
git-31df2c1019733ac22fc848aa2658a0e25af70a79.tar.gz
git-31df2c1019733ac22fc848aa2658a0e25af70a79.tar.bz2
Merge branch 'jk/line-log-with-patch'
"git log -L<from>,<to>:<path>" with "-s" did not suppress the patch output as it should. This has been corrected. * jk/line-log-with-patch: line-log: detect unsupported formats line-log: suppress diff output with "-s"
Diffstat (limited to 'revision.c')
-rw-r--r--revision.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/revision.c b/revision.c
index eb8e51b..cb69a22 100644
--- a/revision.c
+++ b/revision.c
@@ -2689,6 +2689,10 @@ int setup_revisions(int argc, const char **argv, struct rev_info *revs, struct s
if (revs->first_parent_only && revs->bisect)
die(_("--first-parent is incompatible with --bisect"));
+ if (revs->line_level_traverse &&
+ (revs->diffopt.output_format & ~(DIFF_FORMAT_PATCH | DIFF_FORMAT_NO_OUTPUT)))
+ die(_("-L does not yet support diff formats besides -p and -s"));
+
if (revs->expand_tabs_in_log < 0)
revs->expand_tabs_in_log = revs->expand_tabs_in_log_default;