def branch_exists(branch_name, local_only=False, directory=None):
    for branch in get_branches(local_only, directory):
        if branch.startswith('remotes/'):
            branch = branch.split('/')
            if len(branch) > 2:
                branch = '/'.join(branch[2:])
                if branch_name == branch:
                    return True
        else:
            if branch_name == branch:
                return True
    return False
Generate the client credentials
dataset/ETHPy150Open ros-infrastructure/bloom/bloom/git.py/branch_exists--crossover with--dataset/ETHPy150Open datastax/cstar_perf/tool/cstar_perf/tool/fab_deploy.py/generate_client_credentials