Patchwork [03,of,23] configitems: register the 'web.address' config

login
register
mail settings
Submitter Boris Feld
Date Sept. 16, 2017, 6:28 p.m.
Message ID <fcbbdb9dffcf7f029f20.1505586490@FB>
Download mbox | patch
Permalink /patch/23955/
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 1498787132 -7200
#      ven. juin 30 03:45:32 2017 +0200
# Node ID fcbbdb9dffcf7f029f208f27e3470cd7877bc24e
# Parent  e4b7a7d52664e48ccb943d0112d1c2d6d2ab124c
# EXP-Topic config.register.web
configitems: register the 'web.address' config

Patch

diff -r e4b7a7d52664 -r fcbbdb9dffcf mercurial/configitems.py
--- a/mercurial/configitems.py	ven. juin 30 03:45:31 2017 +0200
+++ b/mercurial/configitems.py	ven. juin 30 03:45:32 2017 +0200
@@ -585,6 +585,9 @@ 
 coreconfigitem('web', 'accesslog',
     default='-',
 )
+coreconfigitem('web', 'address',
+    default='',
+)
 coreconfigitem('worker', 'backgroundclose',
     default=dynamicdefault,
 )
diff -r e4b7a7d52664 -r fcbbdb9dffcf mercurial/hgweb/server.py
--- a/mercurial/hgweb/server.py	ven. juin 30 03:45:31 2017 +0200
+++ b/mercurial/hgweb/server.py	ven. juin 30 03:45:32 2017 +0200
@@ -326,7 +326,7 @@ 
         mimetypes.init()
         sys.setdefaultencoding(oldenc)
 
-    address = ui.config('web', 'address', '')
+    address = ui.config('web', 'address')
     port = util.getport(ui.config('web', 'port', 8000))
     try:
         return cls(ui, app, (address, port), handler)