--- a/mercurial/configitems.py Fri Jun 30 03:45:48 2017 +0200
+++ b/mercurial/configitems.py Fri Jun 30 03:45:49 2017 +0200
@@ -631,6 +631,9 @@
coreconfigitem('web', 'port',
default=8000,
)
+coreconfigitem('web', 'prefix',
+ default='',
+)
coreconfigitem('worker', 'backgroundclose',
default=dynamicdefault,
)
--- a/mercurial/hgweb/hgwebdir_mod.py Fri Jun 30 03:45:48 2017 +0200
+++ b/mercurial/hgweb/hgwebdir_mod.py Fri Jun 30 03:45:49 2017 +0200
@@ -177,7 +177,7 @@
if self.stripecount:
self.stripecount = int(self.stripecount)
self._baseurl = self.ui.config('web', 'baseurl')
- prefix = self.ui.config('web', 'prefix', '')
+ prefix = self.ui.config('web', 'prefix')
if prefix.startswith('/'):
prefix = prefix[1:]
if prefix.endswith('/'):
--- a/mercurial/hgweb/server.py Fri Jun 30 03:45:48 2017 +0200
+++ b/mercurial/hgweb/server.py Fri Jun 30 03:45:49 2017 +0200
@@ -277,7 +277,7 @@
handler.preparehttpserver(self, ui)
- prefix = ui.config('web', 'prefix', '')
+ prefix = ui.config('web', 'prefix')
if prefix:
prefix = '/' + prefix.strip('/')
self.prefix = prefix