コード例 #1
0
ファイル: localbranch.py プロジェクト: jmurty/dotfiles
 def instance(ui, path, create):
     path = util.drop_scheme('lbranch', path)
     root = lbranchroot(ui)
     if not root:
         raise util.Abort('local branch parent not available')
     repo = hg.repository(ui, root)
     repo.loadlocalbranch(path)
     return repo
コード例 #2
0
ファイル: __init__.py プロジェクト: dgladkov/hg-git
def _local(path):
    p = hgutil.drop_scheme('file', path)
    if (os.path.exists(os.path.join(p, '.git')) and
        not os.path.exists(os.path.join(p, '.hg'))):
        return gitrepo
    # detect a bare repository
    if (os.path.exists(os.path.join(p, 'HEAD')) and
        os.path.exists(os.path.join(p, 'objects')) and
        os.path.exists(os.path.join(p, 'refs')) and
        not os.path.exists(os.path.join(p, '.hg'))):
        return gitrepo
    return _oldlocal(path)
コード例 #3
0
ファイル: __init__.py プロジェクト: dgladkov/hg-git
def _local(path):
    p = hgutil.drop_scheme('file', path)
    if (os.path.exists(os.path.join(p, '.git'))
            and not os.path.exists(os.path.join(p, '.hg'))):
        return gitrepo
    # detect a bare repository
    if (os.path.exists(os.path.join(p, 'HEAD'))
            and os.path.exists(os.path.join(p, 'objects'))
            and os.path.exists(os.path.join(p, 'refs'))
            and not os.path.exists(os.path.join(p, '.hg'))):
        return gitrepo
    return _oldlocal(path)
コード例 #4
0
ファイル: __init__.py プロジェクト: certik/hg-git
def _local(path):
    p = util.drop_scheme("file", path)
    if os.path.exists(os.path.join(p, ".git")) and not os.path.exists(os.path.join(p, ".hg")):
        return gitrepo
    # detect a bare repository
    if (
        os.path.exists(os.path.join(p, "HEAD"))
        and os.path.exists(os.path.join(p, "objects"))
        and os.path.exists(os.path.join(p, "refs"))
        and not os.path.exists(os.path.join(p, ".hg"))
    ):
        return gitrepo
    return _oldlocal(path)
コード例 #5
0
ファイル: __init__.py プロジェクト: schacon/hg-git
 def __init__(self, path):
     self.p = hgutil.drop_scheme('file', path)
コード例 #6
0
 def __init__(self, path):
     self.p = hgutil.drop_scheme('file', path)
コード例 #7
0
ファイル: __init__.py プロジェクト: hadisdc/dotfiles
 def __init__(self, path):
     self.p = hgutil.drop_scheme("file", path)
コード例 #8
0
ファイル: bfutil.py プロジェクト: steakknife/hg-bfiles
 def urllocalpath(path):
     return util.drop_scheme('file', path)