def get_repo():

    try:
        return Repo(search_parent_directories=True)
    except InvalidGitRepositoryError:
        pass
Returns the current Repo, based on path.
dataset/ETHPy150Open kennethreitz/legit/legit/scm.py/get_repo