def get_repo(api, repo):
    """Get account name, repo name, and repository object from name ``repo``."""
    if '/' in repo:
        user, repo = repo.split('/', 1)
    else:
        user = api.gh_config.user
    return user, repo, api.repository(user, repo)