hgweb: short hash for tip archive name
authorChristian Ebert <blacktrash@gmx.net>
Tue, 13 Mar 2007 13:17:26 +0100
changeset 4282 a1406a50ca83
parent 4281 384672d8080f
child 4283 8625504f507c
hgweb: short hash for tip archive name
mercurial/hgweb/hgweb_mod.py
--- a/mercurial/hgweb/hgweb_mod.py	Mon Mar 26 21:36:26 2007 -0300
+++ b/mercurial/hgweb/hgweb_mod.py	Tue Mar 13 13:17:26 2007 +0100
@@ -610,7 +610,7 @@
         reponame = re.sub(r"\W+", "-", os.path.basename(self.reponame))
         cnode = self.repo.lookup(id)
         arch_version = id
-        if cnode == id:
+        if cnode == id or id == 'tip':
             arch_version = short(cnode)
         name = "%s-%s" % (reponame, arch_version)
         mimetype, artype, extension, encoding = self.archive_specs[type_]