From d13b0d46821a570c11cb723926886824edd83da2 Mon Sep 17 00:00:00 2001 From: pk910 Date: Fri, 7 Sep 2012 22:15:33 +0200 Subject: [PATCH] fixed author links in shortlog --- patch/gitweb.cgi.diff | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/patch/gitweb.cgi.diff b/patch/gitweb.cgi.diff index d7ad041..dd7dbee 100644 --- a/patch/gitweb.cgi.diff +++ b/patch/gitweb.cgi.diff @@ -1,6 +1,6 @@ --- index.cgi 2012-08-29 01:30:10 +0000 -+++ index-graph.cgi 2012-09-07 19:06:10 +0000 -@@ -4764,13 +4768,33 @@ ++++ index-graph.cgi 2012-09-07 20:12:12 +0000 +@@ -4764,13 +4768,37 @@ sub git_shortlog_body { # uses global variable $project @@ -16,18 +16,22 @@ + my $graph_rand = int(rand(99999)); + + my $head = git_get_head_hash($project); ++ my $graph_hash; + if (defined $allrefs && $allrefs == 1) { -+ $hash = "all"; ++ $graph_hash = "all"; + } + if (!defined $hash) { + $hash = $head; + } ++ if(!defined $graph_hash) { ++ $graph_hash = $hash; ++ } + if (!defined $page) { + $page = 0; + } + + print "\n"; -+ print "\n"; ++ print "\n"; + print "Author\n"; + print "Commit\n"; + print "\n"; @@ -36,15 +40,15 @@ for (my $i = $from; $i <= $to; $i++) { my %co = %{$commitlist->[$i]}; my $commit = $co{'id'}; -@@ -4781,6 +4805,7 @@ +@@ -4781,6 +4809,7 @@ print "\n"; } $alternate ^= 1; -+ print ""; ++ print ""; # git_summary() used print "$co{'age_string'}\n" . print "$co{'age_string_date'}\n" . format_author_html('td', \%co, 10) . ""; -@@ -5167,12 +5194,12 @@ +@@ -5167,12 +5198,12 @@ # we need to request one more than 16 (0..15) to check if # those 16 are all @@ -59,7 +63,7 @@ } if (@taglist) { -@@ -5847,8 +5874,10 @@ +@@ -5847,8 +5878,10 @@ my ($fmt_name, $body_subr, $base, $parent, $file_name, $file_hash) = @_; my $head = git_get_head_hash($project); @@ -70,7 +74,7 @@ } if (!defined $page) { $page = 0; -@@ -5856,7 +5885,10 @@ +@@ -5856,7 +5889,10 @@ my $refs = git_get_references(); my $commit_hash = $base; @@ -82,7 +86,7 @@ $commit_hash = "$parent..$base"; } my @commitlist = -@@ -5912,7 +5944,7 @@ +@@ -5912,7 +5948,7 @@ if (defined $file_name); $body_subr->(\@commitlist, 0, 99, $refs, $next_link, -- 2.20.1