changeset 8179:0f3b8404051b

clone: config escaping no longer needed
author Matt Mackall <mpm@selenic.com>
date Sun, 26 Apr 2009 16:50:43 -0500
parents 7b861e5167d0
children 6fc30fe7f3e7
files mercurial/hg.py tests/test-hgrc.out
diffstat 2 files changed, 4 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/hg.py	Sun Apr 26 16:50:09 2009 -0500
+++ b/mercurial/hg.py	Sun Apr 26 16:50:43 2009 -0500
@@ -232,8 +232,7 @@
         if dest_repo.local():
             fp = dest_repo.opener("hgrc", "w", text=True)
             fp.write("[paths]\n")
-            # percent needs to be escaped for ConfigParser
-            fp.write("default = %s\n" % abspath.replace('%', '%%'))
+            fp.write("default = %s\n" % abspath)
             fp.close()
 
             if update:
--- a/tests/test-hgrc.out	Sun Apr 26 16:50:09 2009 -0500
+++ b/tests/test-hgrc.out	Sun Apr 26 16:50:43 2009 -0500
@@ -2,12 +2,12 @@
 updating working directory
 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
 [paths]
-default = .../foo%%bar
-default = .../foo%%bar
+default = .../foo%bar
+default = .../foo%bar
 bundle.mainreporoot=.../foobar
 defaults.backout=-d "0 0"
 defaults.commit=-d "0 0"
 defaults.debugrawcommit=-d "0 0"
 defaults.tag=-d "0 0"
-paths.default=.../foo%%bar
+paths.default=.../foo%bar
 ui.slash=True