diff mercurial/ui.py @ 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 b898afee9d0d
children e6a41cbaa260
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)