Patchwork [20,of,23] configitems: register the 'web.stripes' config

login
register
mail settings
Submitter Boris Feld
Date Sept. 16, 2017, 6:28 p.m.
Message ID <e9ddab0ad36f9740f14c.1505586507@FB>
Download mbox | patch
Permalink /patch/23972/
State Accepted
Headers show

Comments

Boris Feld - Sept. 16, 2017, 6:28 p.m.
# HG changeset patch
# User Boris Feld <boris.feld@octobus.net>
# Date 1498787151 -7200
#      ven. juin 30 03:45:51 2017 +0200
# Node ID e9ddab0ad36f9740f14c142d30fb58ba10204f29
# Parent  dfa73a56a4006e91480b77ca0fbda8ba1e7a454d
# EXP-Topic config.register.web
configitems: register the 'web.stripes' config

Patch

diff -r dfa73a56a400 -r e9ddab0ad36f mercurial/configitems.py
--- a/mercurial/configitems.py	ven. juin 30 03:45:50 2017 +0200
+++ b/mercurial/configitems.py	ven. juin 30 03:45:51 2017 +0200
@@ -637,6 +637,9 @@ 
 coreconfigitem('web', 'refreshinterval',
     default=20,
 )
+coreconfigitem('web', 'stripes',
+    default=1,
+)
 coreconfigitem('worker', 'backgroundclose',
     default=dynamicdefault,
 )
diff -r dfa73a56a400 -r e9ddab0ad36f mercurial/hgweb/hgweb_mod.py
--- a/mercurial/hgweb/hgweb_mod.py	ven. juin 30 03:45:50 2017 +0200
+++ b/mercurial/hgweb/hgweb_mod.py	ven. juin 30 03:45:51 2017 +0200
@@ -99,7 +99,7 @@ 
         self.archivespecs = archivespecs
 
         self.maxchanges = self.configint('web', 'maxchanges', 10)
-        self.stripecount = self.configint('web', 'stripes', 1)
+        self.stripecount = self.configint('web', 'stripes')
         self.maxshortchanges = self.configint('web', 'maxshortchanges', 60)
         self.maxfiles = self.configint('web', 'maxfiles', 10)
         self.allowpull = self.configbool('web', 'allowpull', True)
diff -r dfa73a56a400 -r e9ddab0ad36f mercurial/hgweb/hgwebdir_mod.py
--- a/mercurial/hgweb/hgwebdir_mod.py	ven. juin 30 03:45:50 2017 +0200
+++ b/mercurial/hgweb/hgwebdir_mod.py	ven. juin 30 03:45:51 2017 +0200
@@ -175,7 +175,7 @@ 
         encoding.encoding = self.ui.config('web', 'encoding')
         self.style = self.ui.config('web', 'style', 'paper')
         self.templatepath = self.ui.config('web', 'templates', None)
-        self.stripecount = self.ui.config('web', 'stripes', 1)
+        self.stripecount = self.ui.config('web', 'stripes')
         if self.stripecount:
             self.stripecount = int(self.stripecount)
         self._baseurl = self.ui.config('web', 'baseurl')