diff mercurial/commands.py @ 4866:9858477ed74c

serve: respect settings from .hg/hgrc create_server was looking only at the root ui object, ignoring any settings from .hg/hgrc. To keep respecting command-line arguments, commands.serve must also call repo.ui.setconfig.
author Alexis S. L. Carvalho <alexis@cecm.usp.br>
date Wed, 11 Jul 2007 19:56:16 -0300
parents fc8b3e7cbf6b
children 192cd95c2ba8 242026115e6a
line wrap: on
line diff
--- a/mercurial/commands.py
+++ b/mercurial/commands.py
@@ -2457,6 +2457,8 @@ def serve(ui, repo, **opts):
     for o in optlist.split():
         if opts[o]:
             parentui.setconfig("web", o, str(opts[o]))
+            if repo.ui != parentui:
+                repo.ui.setconfig("web", o, str(opts[o]))
 
     if repo is None and not ui.config("web", "webdir_conf"):
         raise hg.RepoError(_("There is no Mercurial repository here"