# HG changeset patch # User Bryan O'Sullivan # Date 2005-09-23 17:31:00 # Node ID cfae1ed2d61fc33831af115784d3c851b1b89559 # Parent 0fcde73dc3cacb067558027179955cefc3c35f21 Write hgrc file in text mode, even on Windows. diff --git a/mercurial/commands.py b/mercurial/commands.py --- a/mercurial/commands.py +++ b/mercurial/commands.py @@ -624,7 +624,7 @@ def clone(ui, source, dest=None, **opts) abspath = os.path.abspath(source) if not opts['pull']: copy = True - + if copy: try: # we use a lock here because if we race with commit, we @@ -652,7 +652,7 @@ def clone(ui, source, dest=None, **opts) repo = hg.repository(ui, dest, create=1) repo.pull(other) - f = repo.opener("hgrc", "w") + f = repo.opener("hgrc", "w", text=True) f.write("[paths]\n") f.write("default = %s\n" % abspath)