changeset 183:767916673e16

hgweb: Sort tags by revision number
author mpm@selenic.com
date Fri, 27 May 2005 13:30:35 -0800
parents 089594a5bbde
children 697f05bfe976
files mercurial/hgweb.py
diffstat 1 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- 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