hgweb: Sort tags by revision number
authormpm@selenic.com
Fri, 27 May 2005 13:30:35 -0800
changeset 183 767916673e16
parent 182 089594a5bbde
child 184 697f05bfe976
hgweb: Sort tags by revision number
mercurial/hgweb.py
--- a/mercurial/hgweb.py	Fri May 27 13:09:56 2005 -0800
+++ b/mercurial/hgweb.py	Fri May 27 13:30:35 2005 -0800
@@ -512,7 +512,10 @@
 
         self.repo.lookup(0) # prime the cache
         i = self.repo.tags.items()
-        i.sort()
+        n = [ (cl.rev(e[1]), e) for e in i ] # sort by revision
+        n.sort()
+        n.reverse()
+        i = [ e[1] for e in n ]
 
         def entries():
             parity = 0