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>
}
sub git_commitdiff {
- my $format = shift || 'html';
+ my %params = @_;
+ my $format = $params{-format} || 'html';
my $patch_max;
if ($format eq 'patch') {
}
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 {