yoda/repository.py
def clone(url, path):
    """Clone a repository."""
    adapter = None
    if url[:4] == "git@" or url[-4:] == ".git":
        adapter = Git(path)
    if url[:6] == "svn://":
        adapter = Svn(path)
    if url[:6] == "bzr://":
        adapter = Bzr(path)
    if url[:9] == "ssh://hg@":
        adapter = Hg(path)

    if adapter is None:
        raise RepositoryAdapterNotFound(
            "Can't find adapter for `%s` repository url" % url)

    return adapter.clone(url)
def clone(url, path):
    """Clone a repository."""
    adapter = None
    if url[:4] == "git@" or url[-4:] == ".git":
        adapter = Git(path)
    if url[:6] == "svn://":
        adapter = Svn(path)
    if url[:6] == "bzr://":
        adapter = Bzr(path)
    if url[:9] == "ssh://hg@":
        adapter = Hg(path)

    if adapter is None:
        raise RepositoryAdapterNotFound(
            "Can't find adapter for `%s` repository url" % url)

    return adapter.clone(url)
Clone a repository.