# HG changeset patch # User Thomas Arendsen Hein # Date 1140534287 -3600 # Node ID 982fb022a16a46930e48c9adfc6b220b6c824bcb # Parent b9fac31f34c9381252f00739b4b97b2e1d1ffddd# Parent f79afc26ae3b347000ced2d9469213b4a1fbe4e9 Merged RSS feed for tags from Peter van Dijk diff --git a/mercurial/hgweb.py b/mercurial/hgweb.py --- a/mercurial/hgweb.py +++ b/mercurial/hgweb.py @@ -660,9 +660,10 @@ class hgweb(object): i = self.repo.tagslist() i.reverse() - def entries(**map): + def entries(notip=False, **map): parity = 0 for k,n in i: + if notip and k == "tip": continue yield {"parity": parity, "tag": k, "tagmanifest": hex(cl.read(n)[0]), @@ -672,7 +673,8 @@ class hgweb(object): yield self.t("tags", manifest=hex(mf), - entries=entries) + entries=lambda **x: entries(False, **x), + entriesnotip=lambda **x: entries(True, **x)) def summary(self): cl = self.repo.changelog diff --git a/templates/map-rss b/templates/map-rss --- a/templates/map-rss +++ b/templates/map-rss @@ -4,3 +4,5 @@ changelog = changelog-rss.tmpl changelogentry = changelogentry-rss.tmpl filelog = filelog-rss.tmpl filelogentry = filelogentry-rss.tmpl +tags = tags-rss.tmpl +tagentry = tagentry-rss.tmpl diff --git a/templates/tagentry-rss.tmpl b/templates/tagentry-rss.tmpl new file mode 100644 --- /dev/null +++ b/templates/tagentry-rss.tmpl @@ -0,0 +1,6 @@ + + #tag|escape# + #url#?cs=#node|short# + + #date|rfc822date# + diff --git a/templates/tags-rss.tmpl b/templates/tags-rss.tmpl new file mode 100644 --- /dev/null +++ b/templates/tags-rss.tmpl @@ -0,0 +1,6 @@ +#header# + #repo|escape#: tags + #repo|escape# tag history + #entriesnotip%tagentry# + + diff --git a/templates/tags.tmpl b/templates/tags.tmpl --- a/templates/tags.tmpl +++ b/templates/tags.tmpl @@ -1,11 +1,14 @@ #header# #repo|escape#: tags +
changelog manifest +rss

tags: