mercurial/localrepo.py
changeset 46907 ffd3e823a7e5
parent 46902 631001150e13
child 47012 d55b71393907
child 47183 8be95673eb8a
equal deleted inserted replaced
46906:33524c46a092 46907:ffd3e823a7e5
    83 
    83 
    84 from .utils import (
    84 from .utils import (
    85     hashutil,
    85     hashutil,
    86     procutil,
    86     procutil,
    87     stringutil,
    87     stringutil,
       
    88     urlutil,
    88 )
    89 )
    89 
    90 
    90 from .revlogutils import (
    91 from .revlogutils import (
    91     concurrency_checker as revlogchecker,
    92     concurrency_checker as revlogchecker,
    92     constants as revlogconst,
    93     constants as revlogconst,
  3402     assert name.startswith(b'journal')
  3403     assert name.startswith(b'journal')
  3403     return os.path.join(base, name.replace(b'journal', b'undo', 1))
  3404     return os.path.join(base, name.replace(b'journal', b'undo', 1))
  3404 
  3405 
  3405 
  3406 
  3406 def instance(ui, path, create, intents=None, createopts=None):
  3407 def instance(ui, path, create, intents=None, createopts=None):
  3407     localpath = util.urllocalpath(path)
  3408     localpath = urlutil.urllocalpath(path)
  3408     if create:
  3409     if create:
  3409         createrepository(ui, localpath, createopts=createopts)
  3410         createrepository(ui, localpath, createopts=createopts)
  3410 
  3411 
  3411     return makelocalrepository(ui, localpath, intents=intents)
  3412     return makelocalrepository(ui, localpath, intents=intents)
  3412 
  3413