##// END OF EJS Templates
util: rename the util.localpath that uses url to urllocalpath (issue2875)...
Mads Kiilerich -
r14825:de9eb6b1 1.9 stable
parent child Browse files
Show More
@@ -17,7 +17,7 b' import verify as verifymod'
17 import errno, os, shutil
17 import errno, os, shutil
18
18
19 def _local(path):
19 def _local(path):
20 path = util.expandpath(util.localpath(path))
20 path = util.expandpath(util.urllocalpath(path))
21 return (os.path.isfile(path) and bundlerepo or localrepo)
21 return (os.path.isfile(path) and bundlerepo or localrepo)
22
22
23 def addbranchrevs(lrepo, repo, branches, revs):
23 def addbranchrevs(lrepo, repo, branches, revs):
@@ -227,8 +227,8 b' def clone(ui, peeropts, source, dest=Non'
227 else:
227 else:
228 dest = ui.expandpath(dest)
228 dest = ui.expandpath(dest)
229
229
230 dest = util.localpath(dest)
230 dest = util.urllocalpath(dest)
231 source = util.localpath(source)
231 source = util.urllocalpath(source)
232
232
233 if os.path.exists(dest):
233 if os.path.exists(dest):
234 if not os.path.isdir(dest):
234 if not os.path.isdir(dest):
@@ -250,7 +250,7 b' def clone(ui, peeropts, source, dest=Non'
250 try:
250 try:
251 abspath = origsource
251 abspath = origsource
252 if islocal(origsource):
252 if islocal(origsource):
253 abspath = os.path.abspath(util.localpath(origsource))
253 abspath = os.path.abspath(util.urllocalpath(origsource))
254
254
255 if islocal(dest):
255 if islocal(dest):
256 dircleanup = DirCleanup(dest)
256 dircleanup = DirCleanup(dest)
@@ -1985,7 +1985,7 b' def undoname(fn):'
1985 return os.path.join(base, name.replace('journal', 'undo', 1))
1985 return os.path.join(base, name.replace('journal', 'undo', 1))
1986
1986
1987 def instance(ui, path, create):
1987 def instance(ui, path, create):
1988 return localrepository(ui, util.localpath(path), create)
1988 return localrepository(ui, util.urllocalpath(path), create)
1989
1989
1990 def islocal(path):
1990 def islocal(path):
1991 return True
1991 return True
@@ -1589,7 +1589,7 b' def hasscheme(path):'
1589 def hasdriveletter(path):
1589 def hasdriveletter(path):
1590 return path[1:2] == ':' and path[0:1].isalpha()
1590 return path[1:2] == ':' and path[0:1].isalpha()
1591
1591
1592 def localpath(path):
1592 def urllocalpath(path):
1593 return url(path, parsequery=False, parsefragment=False).localpath()
1593 return url(path, parsequery=False, parsefragment=False).localpath()
1594
1594
1595 def hidepassword(u):
1595 def hidepassword(u):
General Comments 0
You need to be logged in to leave comments. Login now