changeset 35131:f38c91c74294

hgweb: rename the main attribute of instabilities Let's make "instabilities" list contain items with "instability" key as opposed to "name" key. This way it's more explicit and more consistent with the log command-line template.
author Anton Shestakov <av6@dwimlabs.net>
date Sun, 26 Nov 2017 13:29:18 +0800
parents 8287df8b7be5
children 34de38f996b9
files mercurial/hgweb/webutil.py mercurial/templates/gitweb/map mercurial/templates/monoblue/map mercurial/templates/paper/map mercurial/templates/spartan/changelogentry.tmpl mercurial/templates/spartan/changeset.tmpl
diffstat 6 files changed, 6 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/hgweb/webutil.py	Thu Nov 23 14:13:14 2017 -0800
+++ b/mercurial/hgweb/webutil.py	Sun Nov 26 13:29:18 2017 +0800
@@ -362,7 +362,7 @@
         'extra': ctx.extra(),
         'phase': ctx.phasestr(),
         'obsolete': ctx.obsolete(),
-        'instabilities': [{"name": i} for i in ctx.instabilities()],
+        'instabilities': [{"instability": i} for i in ctx.instabilities()],
         'branch': nodebranchnodefault(ctx),
         'inbranch': nodeinbranch(repo, ctx),
         'branches': nodebranchdict(repo, ctx),
--- a/mercurial/templates/gitweb/map	Thu Nov 23 14:13:14 2017 -0800
+++ b/mercurial/templates/gitweb/map	Sun Nov 26 13:29:18 2017 +0800
@@ -264,7 +264,7 @@
 graph = graph.tmpl
 phasetag = '{ifeq(phase, 'public', '', '<span class="phasetag" title="{phase|escape}">{phase|escape}</span> ')}'
 obsoletetag = '{if(obsolete, '<span class="obsoletetag" title="obsolete">obsolete</span> ')}'
-instabilitytag = '<span class="instabilitytag" title="{name|escape}">{name|escape}</span> '
+instabilitytag = '<span class="instabilitytag" title="{instability|escape}">{instability|escape}</span> '
 tagtag = '<span class="tagtag" title="{name|escape}">{name|escape}</span> '
 branchtag = '<span class="branchtag" title="{name|escape}">{name|escape}</span> '
 inbranchtag = '<span class="inbranchtag" title="{name|escape}">{name|escape}</span> '
--- a/mercurial/templates/monoblue/map	Thu Nov 23 14:13:14 2017 -0800
+++ b/mercurial/templates/monoblue/map	Sun Nov 26 13:29:18 2017 +0800
@@ -223,7 +223,7 @@
 shortlog = shortlog.tmpl
 phasetag = '{ifeq(phase, 'public', '', '<span class="phasetag" title="{phase|escape}">{phase|escape}</span> ')}'
 obsoletetag = '{if(obsolete, '<span class="obsoletetag" title="obsolete">obsolete</span> ')}'
-instabilitytag = '<span class="instabilitytag" title="{name|escape}">{name|escape}</span> '
+instabilitytag = '<span class="instabilitytag" title="{instability|escape}">{instability|escape}</span> '
 tagtag = '<span class="tagtag" title="{name|escape}">{name|escape}</span> '
 branchtag = '<span class="branchtag" title="{name|escape}">{name|escape}</span> '
 inbranchtag = '<span class="inbranchtag" title="{name|escape}">{name|escape}</span> '
--- a/mercurial/templates/paper/map	Thu Nov 23 14:13:14 2017 -0800
+++ b/mercurial/templates/paper/map	Sun Nov 26 13:29:18 2017 +0800
@@ -200,7 +200,7 @@
   </tr>'
 phasetag = '{ifeq(phase, 'public', '', '<span class="phase">{phase|escape}</span> ')}'
 obsoletetag = '{if(obsolete, '<span class="obsolete">obsolete</span> ')}'
-instabilitytag = '<span class="instability">{name|escape}</span> '
+instabilitytag = '<span class="instability">{instability|escape}</span> '
 changelogtag = '<span class="tag">{name|escape}</span> '
 changesettag = '<span class="tag">{tag|escape}</span> '
 changesetbookmark = '<span class="tag">{bookmark|escape}</span> '
--- a/mercurial/templates/spartan/changelogentry.tmpl	Thu Nov 23 14:13:14 2017 -0800
+++ b/mercurial/templates/spartan/changelogentry.tmpl	Sun Nov 26 13:29:18 2017 +0800
@@ -28,7 +28,7 @@
  </tr>')}
  {ifeq(count(instabilities), '0', '', '<tr>
   <th class="instabilities">instabilities:</th>
-  <td class="instabilities">{instabilities%"{name} "|escape}</td>
+  <td class="instabilities">{instabilities%"{instability} "|escape}</td>
  </tr>')}
  <tr>
   <th class="files"><a href="{url|urlescape}file/{node|short}{sessionvars%urlparameter}">files</a>:</th>
--- a/mercurial/templates/spartan/changeset.tmpl	Thu Nov 23 14:13:14 2017 -0800
+++ b/mercurial/templates/spartan/changeset.tmpl	Sun Nov 26 13:29:18 2017 +0800
@@ -43,7 +43,7 @@
 </tr>')}
 {ifeq(count(instabilities), '0', '', '<tr>
  <th class="instabilities">instabilities:</th>
- <td class="instabilities">{instabilities%"{name} "|escape}</td>
+ <td class="instabilities">{instabilities%"{instability} "|escape}</td>
 </tr>')}
 <tr>
  <th class="files">files:</th>