Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
gitweb: change call pattern for git_commitdiff
author
Giuseppe Bilotta
<giuseppe.bilotta@gmail.com>
Thu, 18 Dec 2008 07:13:17 +0000
(08:13 +0100)
committer
Junio C Hamano
<gitster@pobox.com>
Sun, 21 Dec 2008 09:11:28 +0000
(
01:11
-0800)
Since we are going to introduce an additional parameter for
git_commitdiff to tune patch view, we switch to named/hash-based
parameter passing for clarity and robustness.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
gitweb/gitweb.perl
patch
|
blob
|
history
raw
|
patch
| inline |
side by side
(parent:
9872cd6
)
diff --git
a/gitweb/gitweb.perl
b/gitweb/gitweb.perl
index 9a11be3d94a9492de3d4e2b58cf0a9141bb376c4..63e93a2736d30a714854deae42763a10531d9ba2 100755
(executable)
--- a/
gitweb/gitweb.perl
+++ b/
gitweb/gitweb.perl
@@
-5411,7
+5411,8
@@
sub git_blobdiff_plain {
}
sub git_commitdiff {
- my $format = shift || 'html';
+ my %params = @_;
+ my $format = $params{-format} || 'html';
my $patch_max;
if ($format eq 'patch') {
@@
-5619,12
+5620,12
@@
sub git_commitdiff {
}
sub git_commitdiff_plain {
- git_commitdiff('plain');
+ git_commitdiff(
-format =>
'plain');
}
# format-patch-style patches
sub git_patch {
- git_commitdiff('patch');
+ git_commitdiff(
-format =>
'patch');
}
sub git_history {