# HG changeset patch # User Adrian Buehlmann # Date 1303412085 -7200 # Node ID 26335a817dd07dece5e299f290c9cc2ab2027402 # Parent af60153b5e3b8b3af35b845b7922b405c5635b42 move os_rcpath from util to scmutil diff -r af60153b5e3b -r 26335a817dd0 mercurial/scmutil.py --- a/mercurial/scmutil.py Thu Apr 21 20:14:29 2011 +0200 +++ b/mercurial/scmutil.py Thu Apr 21 20:54:45 2011 +0200 @@ -296,6 +296,13 @@ newdirs.append(d) dirs[:] = newdirs +def os_rcpath(): + '''return default os-specific hgrc search path''' + path = util.system_rcpath() + path.extend(util.user_rcpath()) + path = [os.path.normpath(f) for f in path] + return path + _rcpath = None def rcpath(): @@ -319,5 +326,5 @@ else: _rcpath.append(p) else: - _rcpath = util.os_rcpath() + _rcpath = os_rcpath() return _rcpath diff -r af60153b5e3b -r 26335a817dd0 mercurial/util.py --- a/mercurial/util.py Thu Apr 21 20:14:29 2011 +0200 +++ b/mercurial/util.py Thu Apr 21 20:54:45 2011 +0200 @@ -1083,13 +1083,6 @@ except (UnicodeDecodeError, UnicodeEncodeError): return _ellipsis(text, maxlength)[0] -def os_rcpath(): - '''return default os-specific hgrc search path''' - path = system_rcpath() - path.extend(user_rcpath()) - path = [os.path.normpath(f) for f in path] - return path - def bytecount(nbytes): '''return byte count formatted as readable string, with units'''