[PATCH 2 of 6] rss/atom: add branches page

Sune Foldager cryo at cyanite.org
Mon May 11 14:29:07 CDT 2009


# HG changeset patch
# User Sune Foldager <cryo at cyanite.org>
# Date 1242068838 -7200
# Node ID 6a23ccc1317e2e5c7d0ab7a7a87cdb1749da979f
# Parent  06f4817dddaae0bd6d43d37aacc060624e38caaf
rss/atom: add branches page

diff --git a/templates/atom/branchentry.tmpl b/templates/atom/branchentry.tmpl
new file mode 100644
--- /dev/null
+++ b/templates/atom/branchentry.tmpl
@@ -0,0 +1,8 @@
+ <entry>
+  <title>#branch|escape#</title>
+  <link rel="alternate" href="{urlbase}{url}shortlog/{node}"/>
+  <id>{urlbase}{url}#branch-{node}</id>
+  <updated>#date|rfc3339date#</updated>
+  <published>#date|rfc3339date#</published>
+  <content type="text">#branch|strip|escape#</content>
+ </entry>
diff --git a/templates/atom/branches.tmpl b/templates/atom/branches.tmpl
new file mode 100644
--- /dev/null
+++ b/templates/atom/branches.tmpl
@@ -0,0 +1,11 @@
+#header#
+ <id>{urlbase}{url}</id>
+ <link rel="self" href="{urlbase}{url}atom-branches"/>
+ <link rel="alternate" href="{urlbase}{url}branches"/>
+ <title>#repo|escape#: branches</title>
+ <summary>#repo|escape# branch history</summary>
+ <author><name>Mercurial SCM</name></author>
+ #latestentry%feedupdated#
+
+#entries%branchentry#
+</feed>
diff --git a/templates/atom/map b/templates/atom/map
--- a/templates/atom/map
+++ b/templates/atom/map
@@ -8,4 +8,6 @@
 filelogentry = filelogentry.tmpl
 tags = tags.tmpl
 tagentry = tagentry.tmpl
+branches = branches.tmpl
+branchentry = branchentry.tmpl
 error = error.tmpl
diff --git a/templates/rss/branchentry.tmpl b/templates/rss/branchentry.tmpl
new file mode 100644
--- /dev/null
+++ b/templates/rss/branchentry.tmpl
@@ -0,0 +1,6 @@
+<item>
+    <title>#branch|escape#</title>
+    <link>{urlbase}{url}shortlog/{node|short}</link>
+    <description><![CDATA[#branch|strip|escape|addbreaks#]]></description>
+    <pubDate>#date|rfc822date#</pubDate>
+</item>
diff --git a/templates/rss/branches.tmpl b/templates/rss/branches.tmpl
new file mode 100644
--- /dev/null
+++ b/templates/rss/branches.tmpl
@@ -0,0 +1,6 @@
+#header#
+    <title>#repo|escape#: branches </title>
+    <description>#repo|escape# branch history</description>
+    #entries%branchentry#
+  </channel>
+</rss>
diff --git a/templates/rss/map b/templates/rss/map
--- a/templates/rss/map
+++ b/templates/rss/map
@@ -7,4 +7,6 @@
 filelogentry = filelogentry.tmpl
 tags = tags.tmpl
 tagentry = tagentry.tmpl
+branches = branches.tmpl
+branchentry = branchentry.tmpl
 error = error.tmpl


More information about the Mercurial-devel mailing list