[PATCH 3 of 4 v2] hgweb: rename desc keyword in the summary page to repodesc

Steven Brown stevengbrown at gmail.com
Fri May 16 09:47:14 CDT 2014


# HG changeset patch
# User Steven Brown <StevenGBrown at gmail.com>
# Date 1400245446 -28800
#      Fri May 16 21:04:06 2014 +0800
# Node ID 047159d0c841fe008d1bf7f5d99837f107e974cc
# Parent  8515c010d3452015f92fd37693fd53be93eeb849
hgweb: rename desc keyword in the summary page to repodesc

This allows the check-code script to know the difference between the repository
description and the changeset description, and apply different checks to each.

diff --git a/mercurial/hgweb/webcommands.py b/mercurial/hgweb/webcommands.py
--- a/mercurial/hgweb/webcommands.py
+++ b/mercurial/hgweb/webcommands.py
@@ -639,7 +639,7 @@
     end = min(count, start + web.maxchanges)
 
     return tmpl("summary",
-                desc=web.config("web", "description", "unknown"),
+                repodesc=web.config("web", "description", "unknown"),
                 owner=get_contact(web.config) or "unknown",
                 lastchange=tip.date(),
                 tags=tagentries,
diff --git a/mercurial/templates/gitweb/summary.tmpl b/mercurial/templates/gitweb/summary.tmpl
--- a/mercurial/templates/gitweb/summary.tmpl
+++ b/mercurial/templates/gitweb/summary.tmpl
@@ -33,7 +33,7 @@
 
 <div class="title"> </div>
 <table cellspacing="0">
-<tr><td>description</td><td>{desc}</td></tr>
+<tr><td>description</td><td>{repodesc}</td></tr>
 <tr><td>owner</td><td>{owner|obfuscate}</td></tr>
 <tr><td>last change</td><td>{lastchange|rfc822date}</td></tr>
 </table>
diff --git a/mercurial/templates/monoblue/summary.tmpl b/mercurial/templates/monoblue/summary.tmpl
--- a/mercurial/templates/monoblue/summary.tmpl
+++ b/mercurial/templates/monoblue/summary.tmpl
@@ -35,7 +35,7 @@
         <dt>name</dt>
         <dd>{repo|escape}</dd>
         <dt>description</dt>
-        <dd>{desc}</dd>
+        <dd>{repodesc}</dd>
         <dt>owner</dt>
         <dd>{owner|obfuscate}</dd>
         <dt>last change</dt>


More information about the Mercurial-devel mailing list