Mercurial > hg
comparison mercurial/dispatch.py @ 14860:67add0f24f83
dispatch: fix checking of rpath in _getlocal
This avoids an extra config read
author | Matt Mackall <mpm@selenic.com> |
---|---|
date | Tue, 12 Jul 2011 16:36:34 -0500 |
parents | 1a9256cdf10f |
children | ad6a58581ecd |
comparison
equal
deleted
inserted
replaced
14859:dccecfaebdd2 | 14860:67add0f24f83 |
---|---|
472 lui = ui | 472 lui = ui |
473 else: | 473 else: |
474 lui = ui.copy() | 474 lui = ui.copy() |
475 lui.readconfig(os.path.join(path, ".hg", "hgrc"), path) | 475 lui.readconfig(os.path.join(path, ".hg", "hgrc"), path) |
476 | 476 |
477 if rpath: | 477 if rpath and rpath[-1]: |
478 path = lui.expandpath(rpath[-1]) | 478 path = lui.expandpath(rpath[-1]) |
479 lui = ui.copy() | 479 lui = ui.copy() |
480 lui.readconfig(os.path.join(path, ".hg", "hgrc"), path) | 480 lui.readconfig(os.path.join(path, ".hg", "hgrc"), path) |
481 | 481 |
482 return path, lui | 482 return path, lui |