Did I find the right examples for you? yes no

All Samples(9)  |  Call(5)  |  Derive(0)  |  Import(4)
Returns ``Repository`` object of type linked with given ``alias`` at
the specified ``path``. If ``alias`` is not given it will try to guess it
using get_scm method

        def get_repo(path=None, alias=None, create=False):
    """
    Returns ``Repository`` object of type linked with given ``alias`` at
    the specified ``path``. If ``alias`` is not given it will try to guess it
    using get_scm method
    """
    if create:
        if not (path or alias):
            raise TypeError("If create is specified, we need path and scm type")
        return get_backend(alias)(path, create=True)
    if path is None:
        path = abspath(os.path.curdir)
    try:
        scm, path = get_scm(path, search_up=True)
        path = abspath(path)
        alias = scm
    except VCSError:
        raise VCSError("No scm found at %s" % path)
    if alias is None:
        alias = get_scm(path)[0]

    backend = get_backend(alias)
    repo = backend(path, create=create)
    return repo
        


src/d/j/django-projector-0.2.0/projector/utils/package.py   django-projector(Download)
    """
    try:
        from vcs import get_repo
        from vcs.utils.helpers import get_scm
        from vcs.exceptions import RepositoryError, VCSError
        repopath = os.path.join(os.path.dirname(__file__), '..', '..')
        scm = get_scm(repopath)[0]
        repo = get_repo(path=repopath, alias=scm)

src/d/j/django-projector-HEAD/projector/utils/package.py   django-projector(Download)
        return None
    try:
        from vcs import get_repo
        from vcs.utils.helpers import get_scm
        from vcs.exceptions import RepositoryError, VCSError
        repopath = os.path.join(os.path.dirname(__file__), '..', '..')
        scm = get_scm(repopath)[0]
        repo = get_repo(path=repopath, alias=scm)

src/x/i/xilinx-build-scripts-HEAD/xil_vc.py   xilinx-build-scripts(Download)
    xil_sources_norm = [path_ptv(f) for f in xil_sources]
 
    repo=vcs.get_repo(path=opts.repo_root)
    head=repo.get_changeset()
 

src/v/c/vcs-0.4.0/vcs/cli.py   vcs(Download)
            try:
                scm, path = get_scm(curdir, search_up=True)
                self.repo = vcs.get_repo(path, scm)
            except VCSError:
                raise CommandError('Repository not found')

src/v/c/vcs-HEAD/vcs/cli.py   vcs(Download)
            try:
                scm, path = get_scm(curdir, search_up=True)
                self.repo = vcs.get_repo(path, scm)
            except VCSError:
                raise CommandError('Repository not found')

src/v/c/vcs-HEAD/vcs/tests/test_vcs.py   vcs(Download)
import shutil
 
from vcs import VCSError, get_repo, get_backend
from vcs.backends.hg import MercurialRepository
from vcs.utils.compat import unittest

src/v/c/vcs-0.4.0/vcs/tests/test_vcs.py   vcs(Download)
import shutil
 
from vcs import VCSError, get_repo, get_backend
from vcs.backends.hg import MercurialRepository
from vcs.utils.compat import unittest