Patchwork hgweb: add shortlog and search templates to raw style

login
register
mail settings
Submitter Alexander Plavin
Date July 11, 2013, 10:09 p.m.
Message ID <8bb0a3d04cadbc090527.1373580594@debian-alexander.dolgopa>
Download mbox | patch
Permalink /patch/1834/
State Superseded
Headers show

Comments

Alexander Plavin - July 11, 2013, 10:09 p.m.
# HG changeset patch
# User Alexander Plavin <me@aplavin.ru>
# Date 1373321304 -14400
#      Tue Jul 09 02:08:24 2013 +0400
# Node ID 8bb0a3d04cadbc09052739ae09fa1ebe2d65071e
# Parent  497a02df2e92dfe07fcd22217829319f6ac94388
hgweb: add shortlog and search templates to raw style

This will make testing hgweb search and other things simpler and more concise,
as there is no extra HTML code in the raw style.

Patch

diff -r 497a02df2e92 -r 8bb0a3d04cad mercurial/templates/raw/map
--- a/mercurial/templates/raw/map	Sat Jun 29 14:36:51 2013 +0400
+++ b/mercurial/templates/raw/map	Tue Jul 09 02:08:24 2013 +0400
@@ -1,5 +1,8 @@ 
 default = 'shortlog'
-shortlog = "'raw' is not a browsable style"
+shortlog = shortlog.tmpl
+shortlogentry = shortlogentry.tmpl
+search = search.tmpl
+searchentry = shortlogentry.tmpl
 mimetype = 'text/plain; charset={encoding}'
 header = ''
 footer = ''
diff -r 497a02df2e92 -r 8bb0a3d04cad mercurial/templates/raw/search.tmpl
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mercurial/templates/raw/search.tmpl	Tue Jul 09 02:08:24 2013 +0400
@@ -0,0 +1,6 @@ 
+{header}
+# HG changesets search
+# Node ID {node}
+# Query "{query}"
+
+{entries%shortlogentry}
diff -r 497a02df2e92 -r 8bb0a3d04cad mercurial/templates/raw/shortlog.tmpl
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mercurial/templates/raw/shortlog.tmpl	Tue Jul 09 02:08:24 2013 +0400
@@ -0,0 +1,5 @@ 
+{header}
+# HG shortlog
+# Node ID {node}
+
+{entries%shortlogentry}
diff -r 497a02df2e92 -r 8bb0a3d04cad mercurial/templates/raw/shortlogentry.tmpl
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mercurial/templates/raw/shortlogentry.tmpl	Tue Jul 09 02:08:24 2013 +0400
@@ -0,0 +1,5 @@ 
+changeset:   {node}
+user:        {author}
+date:        {date|rfc822date}
+summary:     {desc}
+{branches%branchname}{tags%tagname}{bookmarks%bookmarkname}