Patchwork [stable] convert: use original local encoding when converting from Perfoce

login
register
mail settings
Submitter Eugene Baranov
Date July 22, 2015, 3:58 p.m.
Message ID <72aa4232ec5d25c43378.1437580701@ADNADTX6400256.eng.citrite.net>
Download mbox | patch
Permalink /patch/10053/
State Superseded
Headers show

Comments

Eugene Baranov - July 22, 2015, 3:58 p.m.
# HG changeset patch
# User Eugene Baranov <eug.baranov@gmail.com>
# Date 1437580631 -3600
#      Wed Jul 22 16:57:11 2015 +0100
# Node ID 72aa4232ec5d25c4337839eb65093a85f65e44ee
# Parent  bcb96f98d9cfade5098a9a12b49714d218441f83
convert: use original local encoding when converting from Perfoce

Patch

diff -r bcb96f98d9cf -r 72aa4232ec5d hgext/convert/p4.py
--- a/hgext/convert/p4.py	Thu Jul 16 17:57:38 2015 +0100
+++ b/hgext/convert/p4.py	Wed Jul 22 16:57:11 2015 +0100
@@ -9,6 +9,7 @@ 
 from mercurial.i18n import _
 
 from common import commit, converter_source, checktool, NoRepo
+import convcmd
 import marshal
 import re
 
@@ -139,7 +140,7 @@ 
         self.tags = {}
         self.lastbranch = {}
         self.parent = {}
-        self.encoding = "latin_1"
+        self.encoding = convcmd.orig_encoding
         self.depotname = {}           # mapping from local name to depot name
         self.localname = {} # mapping from depot name to local name
         self.re_type = re.compile(