def checkout_branch(branch):

    repo_check()

    _, stdout, stderr = repo.git.execute([git, 'checkout', branch],
                                         with_extended_output=True)
    return '\n'.join([stderr, stdout])
Checks out given branch.
dataset/ETHPy150Open kennethreitz/legit/legit/scm.py/checkout_branch