equal
deleted
inserted
replaced
36 rcpath.append(os.path.join(progrcd, f)) |
36 rcpath.append(os.path.join(progrcd, f)) |
37 # else look for a system rcpath in the registry |
37 # else look for a system rcpath in the registry |
38 value = util.lookupreg( |
38 value = util.lookupreg( |
39 b'SOFTWARE\\Mercurial', None, winreg.HKEY_LOCAL_MACHINE |
39 b'SOFTWARE\\Mercurial', None, winreg.HKEY_LOCAL_MACHINE |
40 ) |
40 ) |
41 if not isinstance(value, str) or not value: |
41 if not isinstance(value, bytes) or not value: |
42 return rcpath |
42 return rcpath |
43 value = util.localpath(value) |
43 value = util.localpath(value) |
44 for p in value.split(pycompat.ospathsep): |
44 for p in value.split(pycompat.ospathsep): |
45 if p.lower().endswith(b'mercurial.ini'): |
45 if p.lower().endswith(b'mercurial.ini'): |
46 rcpath.append(p) |
46 rcpath.append(p) |