gitweb: Use @diff_opts while using format-patch
authorPavan Kumar Sunkara <pavan.sss1991@gmail.com>
Mon, 10 May 2010 16:41:35 +0000 (18:41 +0200)
committerJunio C Hamano <gitster@pobox.com>
Wed, 19 May 2010 04:45:04 +0000 (21:45 -0700)
Make git-format-patch (used by 'patch' and 'patches' views) use the
same rename detection options that git-diff and git-diff-tree (used
by 'commitdiff', 'blobdiff', etc.) use.

Signed-off-by: Pavan Kumar Sunkara <pavan.sss1991@gmail.com>
Acked-by: Jakub Narebski <jnareb@gmail.com>
Acked-by: Giuseppe Bilotta <giuseppe.bilotta@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
gitweb/gitweb.perl

index c356e95f18f0f784584ce644c08e1966ca1be52f..77e5f795a1d0ff847b19b03336cb090155bf3113 100755 (executable)
@@ -6117,8 +6117,8 @@ sub git_commitdiff {
                        }
                        push @commit_spec, '--root', $hash;
                }
-               open $fd, "-|", git_cmd(), "format-patch", '--encoding=utf8',
-                       '--stdout', @commit_spec
+               open $fd, "-|", git_cmd(), "format-patch", @diff_opts,
+                       '--encoding=utf8', '--stdout', @commit_spec
                        or die_error(500, "Open git-format-patch failed");
        } else {
                die_error(400, "Unknown commitdiff format");