Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion bloom/commands/release.py
Original file line number Diff line number Diff line change
Expand Up @@ -744,7 +744,11 @@ def _my_run(cmd, msg=None):
_my_run("mkdir -p {base_info[repo]}".format(**locals()))
with change_directory(base_info['repo']):
_my_run('git init')
branches = [x['name'] for x in gh.list_branches(head_org, head_repo)]
# Use git ls-remote to find existing branches on the fork
ls_remote_cmd = "git ls-remote --heads {rosdistro_fork_url}".format(**locals())
from bloom.util import check_output
branches_out = check_output(ls_remote_cmd, shell=True)
branches = [l.split()[1].replace('refs/heads/', '') for l in branches_out.splitlines()]
new_branch = 'bloom-{repository}-{count}'
count = 0
while new_branch.format(repository=repository, count=count) in branches:
Expand Down
Loading