From b11ddb88e608a6dd5e95f95bff2c506674c4fad8 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Mon, 28 Jan 2008 20:34:11 -0500 Subject: add an id field to the rcs_recentchanges return structure There was an undocumented field named "rev", I think "id" is a better name, and nothing uses it yet. --- IkiWiki/Rcs/Stub.pm | 1 + IkiWiki/Rcs/git.pm | 2 +- IkiWiki/Rcs/mercurial.pm | 2 +- IkiWiki/Rcs/monotone.pm | 2 +- IkiWiki/Rcs/svn.pm | 3 ++- IkiWiki/Rcs/tla.pm | 3 ++- 6 files changed, 8 insertions(+), 5 deletions(-) diff --git a/IkiWiki/Rcs/Stub.pm b/IkiWiki/Rcs/Stub.pm index 19ecfa88d..a979ce3fe 100644 --- a/IkiWiki/Rcs/Stub.pm +++ b/IkiWiki/Rcs/Stub.pm @@ -37,6 +37,7 @@ sub rcs_recentchanges ($) { # Examine the RCS history and generate a list of recent changes. # The data structure returned for each change is: # { + # id => # the RCSs id for this commit # user => # name of user who made the change, # committype => # either "web" or the name of the rcs, # when => # time when the change was made, diff --git a/IkiWiki/Rcs/git.pm b/IkiWiki/Rcs/git.pm index 80ffdced2..9640acfbe 100644 --- a/IkiWiki/Rcs/git.pm +++ b/IkiWiki/Rcs/git.pm @@ -407,7 +407,7 @@ sub rcs_recentchanges ($) { #{{{ } push @rets, { - rev => $sha1, + id => $sha1, user => $user, committype => $type, when => $when, diff --git a/IkiWiki/Rcs/mercurial.pm b/IkiWiki/Rcs/mercurial.pm index 15edb3245..e5258b111 100644 --- a/IkiWiki/Rcs/mercurial.pm +++ b/IkiWiki/Rcs/mercurial.pm @@ -139,7 +139,7 @@ sub rcs_recentchanges ($) { #{{{ $user =~ s/^\s*//; push @ret, { - rev => $info->{"changeset"}, + id => $info->{"changeset"}, user => $user, committype => "mercurial", when => time - str2time($info->{"date"}), diff --git a/IkiWiki/Rcs/monotone.pm b/IkiWiki/Rcs/monotone.pm index 5717e0043..e0f2e046a 100644 --- a/IkiWiki/Rcs/monotone.pm +++ b/IkiWiki/Rcs/monotone.pm @@ -438,7 +438,7 @@ sub rcs_recentchanges ($) { #{{{ } push @ret, { - rev => $rev, + id => $rev, user => $user, committype => $committype, when => $when, diff --git a/IkiWiki/Rcs/svn.pm b/IkiWiki/Rcs/svn.pm index 987469ba0..a32b0a840 100644 --- a/IkiWiki/Rcs/svn.pm +++ b/IkiWiki/Rcs/svn.pm @@ -203,7 +203,8 @@ sub rcs_recentchanges ($) { #{{{ diffurl => $diffurl, } if length $file; } - push @ret, { rev => $rev, + push @ret, { + id => $rev, user => $user, committype => $committype, when => $when, diff --git a/IkiWiki/Rcs/tla.pm b/IkiWiki/Rcs/tla.pm index 1dbc006c1..5275500c3 100644 --- a/IkiWiki/Rcs/tla.pm +++ b/IkiWiki/Rcs/tla.pm @@ -145,7 +145,8 @@ sub rcs_recentchanges ($) { diffurl => $diffurl, } if length $file; } - push @ret, { rev => $change, + push @ret, { + id => $change, user => $user, committype => $committype, when => $when, -- cgit v1.2.3