configitems: register the 'web.maxchanges' config
authorBoris Feld <boris.feld@octobus.net>
Wed, 11 Oct 2017 03:41:48 +0200
changeset 34590 95f4e5b1ec92
parent 34589 883d06211973
child 34591 f00eef0922ff
configitems: register the 'web.maxchanges' config
mercurial/configitems.py
mercurial/hgweb/hgweb_mod.py
--- a/mercurial/configitems.py	Wed Oct 11 03:41:01 2017 +0200
+++ b/mercurial/configitems.py	Wed Oct 11 03:41:48 2017 +0200
@@ -730,6 +730,9 @@
 coreconfigitem('web', 'ipv6',
     default=False,
 )
+coreconfigitem('web', 'maxchanges',
+    default=10,
+)
 coreconfigitem('web', 'maxfiles',
     default=10,
 )
--- a/mercurial/hgweb/hgweb_mod.py	Wed Oct 11 03:41:01 2017 +0200
+++ b/mercurial/hgweb/hgweb_mod.py	Wed Oct 11 03:41:48 2017 +0200
@@ -110,7 +110,7 @@
 
         self.archivespecs = archivespecs
 
-        self.maxchanges = self.configint('web', 'maxchanges', 10)
+        self.maxchanges = self.configint('web', 'maxchanges')
         self.stripecount = self.configint('web', 'stripes')
         self.maxshortchanges = self.configint('web', 'maxshortchanges')
         self.maxfiles = self.configint('web', 'maxfiles')