]> Lady’s Gitweb - Gitweb/commitdiff
gitweb: Use author_epoch for pubdate in gitweb feeds
authorJakub Narebski <redacted>
Sat, 25 Nov 2006 14:54:34 +0000 (15:54 +0100)
committerLady <redacted>
Mon, 6 Apr 2026 04:07:11 +0000 (00:07 -0400)
Use creation date (author_epoch) instead of former commit date
(committer_epoch) as publish date in gitweb feeds (RSS, Atom).

Signed-off-by: Jakub Narebski <redacted>
Signed-off-by: Junio C Hamano <redacted>
gitweb.perl

index b9d1c09f856ca0d238b6e1a3f18e275b6695cbd21c3b32fcc0aec421bd72a8c2..097431299b7a35ec5af09f9b881aeee5e6cb0bce6c4245ef405eeda5a5c31456 100755 (executable)
@@ -4202,7 +4202,7 @@ sub git_feed {
        }
        if (defined($revlist[0])) {
                %latest_commit = parse_commit($revlist[0]);
-               %latest_date   = parse_date($latest_commit{'committer_epoch'});
+               %latest_date   = parse_date($latest_commit{'author_epoch'});
                print $cgi->header(
                        -type => $content_type,
                        -charset => 'utf-8',
@@ -4295,10 +4295,10 @@ XML
                my $commit = $revlist[$i];
                my %co = parse_commit($commit);
                # we read 150, we always show 30 and the ones more recent than 48 hours
-               if (($i >= 20) && ((time - $co{'committer_epoch'}) > 48*60*60)) {
+               if (($i >= 20) && ((time - $co{'author_epoch'}) > 48*60*60)) {
                        last;
                }
-               my %cd = parse_date($co{'committer_epoch'});
+               my %cd = parse_date($co{'author_epoch'});
 
                # get list of changed files
                open $fd, "-|", git_cmd(), "diff-tree", '-r', @diff_opts,
This page took 0.339352 seconds and 4 git commands to generate.