--- a/mercurial/hgweb.py Sun Jan 29 00:31:11 2006 +0100
+++ b/mercurial/hgweb.py Sun Jan 29 17:10:38 2006 +1300
@@ -222,6 +222,12 @@
for s in siblings:
yield dict(node=hex(s), rev=rev(s), **args)
+ def renamelink(self, fl, node):
+ r = fl.renamed(node)
+ if r:
+ return [dict(file=r[0], node=hex(r[1]))]
+ return []
+
def showtag(self, t1, node=nullid, **args):
for t in self.repo.nodetags(node):
yield self.t(t1, tag=t, **args)
@@ -466,6 +472,7 @@
"node": hex(cn),
"author": cs[1],
"date": cs[2],
+ "rename": self.renamelink(fl, n),
"parent": self.siblings(fl.parents(n),
fl.rev, file=f),
"child": self.siblings(fl.children(n),
@@ -514,6 +521,7 @@
date=cs[2],
parent=self.siblings(fl.parents(n), fl.rev, file=f),
child=self.siblings(fl.children(n), fl.rev, file=f),
+ rename=self.renamelink(fl, n),
permissions=self.repo.manifest.readflags(mfn)[f])
def fileannotate(self, f, node):
@@ -565,6 +573,7 @@
manifest=hex(mfn),
author=cs[1],
date=cs[2],
+ rename=self.renamelink(fl, n),
parent=self.siblings(fl.parents(n), fl.rev, file=f),
child=self.siblings(fl.children(n), fl.rev, file=f),
permissions=self.repo.manifest.readflags(mfn)[f])
--- a/templates/fileannotate.tmpl Sun Jan 29 00:31:11 2006 +0100
+++ b/templates/fileannotate.tmpl Sun Jan 29 17:10:38 2006 +1300
@@ -18,6 +18,7 @@
<tr>
<td class="metatag">changeset #rev#:</td>
<td><a href="?cs=#node|short#">#node|short#</a></td></tr>
+#rename%filerename#
#parent%fileannotateparent#
#child%fileannotatechild#
<tr>
--- a/templates/filelogentry.tmpl Sun Jan 29 00:31:11 2006 +0100
+++ b/templates/filelogentry.tmpl Sun Jan 29 17:10:38 2006 +1300
@@ -8,6 +8,7 @@
<a href="?fd=#node|short#;file=#file|urlescape#">(diff)</a>
<a href="?fa=#filenode|short#;file=#file|urlescape#">(annotate)</a>
</td></tr>
+#rename%filelogrename#
<tr>
<td align="right">author: </td>
<td>#author|obfuscate#</td></tr>
--- a/templates/filerevision.tmpl Sun Jan 29 00:31:11 2006 +0100
+++ b/templates/filerevision.tmpl Sun Jan 29 17:10:38 2006 +1300
@@ -19,6 +19,7 @@
<tr>
<td class="metatag">changeset #rev#:</td>
<td><a href="?cs=#node|short#">#node|short#</a></td></tr>
+#rename%filerename#
#parent%filerevparent#
#child%filerevchild#
<tr>
--- a/templates/map Sun Jan 29 00:31:11 2006 +0100
+++ b/templates/map Sun Jan 29 17:10:38 2006 +1300
@@ -27,6 +27,8 @@
changelogparent = "<tr><th class="parent">parent #rev#:</th><td class="parent"><a href="?cs=#node|short#">#node|short#</a></td></tr>"
changesetparent = "<tr><th class="parent">parent #rev#:</th><td class="parent"><a href="?cs=#node|short#">#node|short#</a></td></tr>"
filerevparent = "<tr><td class="metatag">parent:</td><td><a href="?f=#node|short#;file=#file|urlescape#">#node|short#</a></td></tr>"
+filerename = "<tr><td class="metatag">parent:</td><td><a href="?f=#node|short#;file=#file|urlescape#">#file|escape#@#node|short#</a></td></tr>"
+filelogrename = "<tr><td align="right">base: </td><td><a href="?f=#node|short#;file=#file|urlescape#">#file|escape#@#node|short#</a></td></tr>"
fileannotateparent = "<tr><td class="metatag">parent:</td><td><a href="?fa=#filenode|short#;file=#file|urlescape#">#node|short#</a></td></tr>"
changesetchild = "<tr><th class="child">child #rev#:</th><td class="child"><a href="?cs=#node|short#">#node|short#</a></td></tr>"
changelogchild = "<tr><th class="child">child #rev#:</th><td class="child"><a href="?cs=#node|short#">#node|short#</a></td></tr>"