Mercurial > public > mercurial-scm > hg
diff mercurial/scmutil.py @ 30305:af7c60988f6e
py3: make scmutil.rcpath() return bytes
This patch make sure scmutil.rcpath() returns bytes independent of
which platform is used on Python 3. If we want to change type for windows we
can just conditionalize the return variable.
author | Pulkit Goyal <7895pulkit@gmail.com> |
---|---|
date | Sun, 06 Nov 2016 04:17:19 +0530 |
parents | 96a2278ee732 |
children | 4b1af1c867fa |
line wrap: on
line diff
--- a/mercurial/scmutil.py Sun Nov 06 04:10:33 2016 +0530 +++ b/mercurial/scmutil.py Sun Nov 06 04:17:19 2016 +0530 @@ -27,6 +27,7 @@ osutil, pathutil, phases, + pycompat, revset, similar, util, @@ -755,7 +756,7 @@ if _rcpath is None: if 'HGRCPATH' in encoding.environ: _rcpath = [] - for p in os.environ['HGRCPATH'].split(os.pathsep): + for p in encoding.environ['HGRCPATH'].split(pycompat.ospathsep): if not p: continue p = util.expandpath(p)