changeset 2624:46e52bbb9b1a

expand the path if destination is not a directory
author Benoit Boissinot <benoit.boissinot@ens-lyon.org>
date Sun, 16 Jul 2006 00:01:41 +0200
parents 0b4bff2b0ce3
children 70d65ca6d893
files mercurial/ui.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/ui.py
+++ b/mercurial/ui.py
@@ -209,7 +209,7 @@ class ui(object):
 
     def expandpath(self, loc, default=None):
         """Return repository location relative to cwd or from [paths]"""
-        if "://" in loc or os.path.exists(loc):
+        if "://" in loc or os.path.isdir(loc):
             return loc
 
         path = self.config("paths", loc)