diff --git a/mercurial/hgweb/hgweb_mod.py b/mercurial/hgweb/hgweb_mod.py
--- a/mercurial/hgweb/hgweb_mod.py
+++ b/mercurial/hgweb/hgweb_mod.py
@@ -133,6 +133,16 @@ class hgweb(object):
return [dict(file=r[0], node=hex(r[1]))]
return []
+ def taglistdict(self,node):
+ return [{"name":i} for i in self.repo.nodetags(node)]
+
+ def branchlistdict(self,node):
+ l=[]
+ for t, tn in self.repo.branchtags().items():
+ if tn == node:
+ l.append({"name":t})
+ return l
+
def showtag(self, t1, node=nullid, **args):
for t in self.repo.nodetags(node):
yield self.t(t1, tag=t, **args)
@@ -211,7 +221,9 @@ class hgweb(object):
"date": ctx.date(),
"files": self.listfilediffs(ctx.files(), n),
"rev": i,
- "node": hex(n)})
+ "node": hex(n),
+ "tags": self.taglistdict(n),
+ "branches": self.branchlistdict(n)})
for e in l:
yield e
@@ -274,7 +286,9 @@ class hgweb(object):
date=ctx.date(),
files=self.listfilediffs(ctx.files(), n),
rev=ctx.rev(),
- node=hex(n))
+ node=hex(n),
+ tags=self.taglistdict(n),
+ branches=self.branchlistdict(n))
if count >= self.maxchanges:
break
@@ -314,7 +328,9 @@ class hgweb(object):
desc=ctx.description(),
date=ctx.date(),
files=files,
- archives=self.archivelist(hex(n)))
+ archives=self.archivelist(hex(n)),
+ tags=self.taglistdict(n),
+ branches=self.branchlistdict(n))
def filelog(self, fctx):
f = fctx.path()
@@ -482,7 +498,9 @@ class hgweb(object):
upparity=parity.next(),
fentries=filelist,
dentries=dirlist,
- archives=self.archivelist(hex(node)))
+ archives=self.archivelist(hex(node)),
+ tags=self.taglistdict(node),
+ branches=self.branchlistdict(node))
def tags(self):
i = self.repo.tagslist()
@@ -545,7 +563,8 @@ class hgweb(object):
l = [] # build a list in forward order for efficiency
for i in xrange(start, end):
ctx = self.repo.changectx(i)
- hn = hex(ctx.node())
+ n = ctx.node()
+ hn = hex(n)
l.insert(0, self.t(
'shortlogentry',
@@ -554,7 +573,9 @@ class hgweb(object):
desc=ctx.description(),
date=ctx.date(),
rev=i,
- node=hn))
+ node=hn,
+ tags=self.taglistdict(n),
+ branches=self.branchlistdict(n)))
yield l
diff --git a/templates/gitweb/changelogentry.tmpl b/templates/gitweb/changelogentry.tmpl
--- a/templates/gitweb/changelogentry.tmpl
+++ b/templates/gitweb/changelogentry.tmpl
@@ -1,5 +1,5 @@
diff --git a/templates/gitweb/changeset.tmpl b/templates/gitweb/changeset.tmpl
--- a/templates/gitweb/changeset.tmpl
+++ b/templates/gitweb/changeset.tmpl
@@ -14,7 +14,7 @@
@@ -23,7 +23,6 @@
changeset {rev} | {node|short} |
#parent%changesetparent#
#child%changesetchild#
-#changesettag#
diff --git a/templates/gitweb/manifest.tmpl b/templates/gitweb/manifest.tmpl
--- a/templates/gitweb/manifest.tmpl
+++ b/templates/gitweb/manifest.tmpl
@@ -18,7 +18,7 @@ manifest |
changeset #archives%archiveentry#
-
#path|escape#
+
#path|escape# {branches%branchtag}{tags%tagtag}
drwxr-xr-x |
diff --git a/templates/gitweb/map b/templates/gitweb/map
--- a/templates/gitweb/map
+++ b/templates/gitweb/map
@@ -41,14 +41,14 @@ tags = tags.tmpl
tagentry = '
#date|age# ago | #tag|escape# | changeset | changelog | manifest |
'
branchentry = '{date|age} ago | {node|short} | {branch|escape} | changeset | changelog | manifest |
'
diffblock = '#lines#
'
-changelogtag = 'tag: | #tag|escape# |
'
-changesettag = 'tag | #tag|escape# |
'
filediffparent = 'parent {rev} | {node|short} |
'
filelogparent = 'parent #rev#: | #node|short# |
'
filediffchild = 'child {rev} | {node|short} |
'
filelogchild = 'child #rev#: | #node|short# |
'
shortlog = shortlog.tmpl
-shortlogentry = '#date|age# ago | #author|obfuscate# | #desc|strip|firstline|escape# | changeset | manifest |
'
+tagtag = '{name} '
+branchtag = '{name} '
+shortlogentry = '#date|age# ago | #author# | #desc|strip|firstline|escape# {branches%branchtag}{tags%tagtag} | changeset | manifest |
'
filelogentry = '#date|age# ago | #desc|strip|firstline|escape# | file | diff | annotate #rename%filelogrename# |
'
archiveentry = ' | #type|escape# '
indexentry = '#name|escape# | #description# | #contact|obfuscate# | #lastchange|age# ago | #archives%archiveentry# |
'
diff --git a/templates/static/style-gitweb.css b/templates/static/style-gitweb.css
--- a/templates/static/style-gitweb.css
+++ b/templates/static/style-gitweb.css
@@ -48,3 +48,19 @@ a.rss_logo {
}
a.rss_logo:hover { background-color:#ee5500; }
pre { margin: 0; }
+span.logtags span {
+ padding: 0px 4px;
+ font-size: 10px;
+ font-weight: normal;
+ border: 1px solid;
+ background-color: #ffaaff;
+ border-color: #ffccff #ff00ee #ff00ee #ffccff;
+}
+span.logtags span.tagtag {
+ background-color: #ffffaa;
+ border-color: #ffffcc #ffee00 #ffee00 #ffffcc;
+}
+span.logtags span.branchtag {
+ background-color: #aaffaa;
+ border-color: #ccffcc #00cc33 #00cc33 #ccffcc;
+}