[PATCH 06 of 11] dispatch: set ui.insecureconnections when --insecure is used

Gregory Szorc gregory.szorc at gmail.com
Thu May 5 03:53:23 EDT 2016


# HG changeset patch
# User Gregory Szorc <gregory.szorc at gmail.com>
# Date 1462433662 25200
#      Thu May 05 00:34:22 2016 -0700
# Node ID a34fbd2d6235b34319d857bbbb313f1cc53d554b
# Parent  328a6fef953a7f6de589b6132c7927676415386e
dispatch: set ui.insecureconnections when --insecure is used

diff --git a/mercurial/dispatch.py b/mercurial/dispatch.py
--- a/mercurial/dispatch.py
+++ b/mercurial/dispatch.py
@@ -820,16 +820,18 @@ def _dispatch(req):
             ui_.setconfig('ui', 'traceback', 'on', '--traceback')
 
     if options['noninteractive']:
         for ui_ in uis:
             ui_.setconfig('ui', 'interactive', 'off', '-y')
 
     if cmdoptions.get('insecure', False):
         for ui_ in uis:
+            ui_.insecureconnections = True
+            # TODO remove once consumers are gone.
             ui_.setconfig('web', 'cacerts', '!', '--insecure')
 
     if options['version']:
         return commands.version_(ui)
     if options['help']:
         return commands.help_(ui, cmd, command=cmd is not None)
     elif not cmd:
         return commands.help_(ui, 'shortlist')


More information about the Mercurial-devel mailing list